Skip to content

Commit c336fff

Browse files
committed
docs: change describe style
2 parents 617ce7b + 3eab0f1 commit c336fff

File tree

121 files changed

+24038
-356
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

121 files changed

+24038
-356
lines changed

CHANGELOG.md

Lines changed: 38 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,41 @@
1-
## 1.44.1 (Unreleased)
1+
## 1.45.1 (Unreleased)
2+
3+
ENHANCEMENTS:
4+
5+
* Resource: `tencentcloud_clb_target_group_instance_attachment` update doc
6+
* Resource: `tencentcloud_clb_target_group_attachment` update doc
7+
8+
## 1.45.0 (October 15, 2020)
9+
10+
FEATURES:
11+
12+
* **New Resource**: `tencentcloud_clb_target_group_attachment`
13+
* **New Resource**: `tencentcloud_clb_target_group`
14+
* **New Resource**: `tencentcloud_clb_target_group_instance_attachment`
15+
* **New Resource**: `tencentcloud_sqlserver_publish_subscribe`
16+
* **New Resource**: `tencentcloud_vod_adaptive_dynamic_streaming_template`
17+
* **New Resource**: `tencentcloud_vod_procedure_template`
18+
* **New Resource**: `tencentcloud_vod_snapshot_by_time_offset_template`
19+
* **New Resource**: `tencentcloud_vod_image_sprite_template`
20+
* **New Resource**: `tencentcloud_vod_super_player_config`
21+
* **New Data Source**: `tencentcloud_clb_target_groups`
22+
* **New Data Source**: `tencentcloud_sqlserver_publish_subscribes`
23+
* **New Data Source**: `tencentcloud_vod_adaptive_dynamic_streaming_templates`
24+
* **New Data Source**: `tencentcloud_vod_image_sprite_templates`
25+
* **New Data Source**: `tencentcloud_vod_procedure_templates`
26+
* **New Data Source**: `tencentcloud_vod_snapshot_by_time_offset_templates`
27+
* **New Data Source**: `tencentcloud_vod_super_player_configs`
28+
29+
ENHANCEMENTS:
30+
31+
* Resource: `tencentcloud_clb_listener_rule` add new argument `target_type` to support backend target type with rule.
32+
* Resource: `tencentcloud_mysql_instance` modify argument `engine_version` to support mysql 8.0.
33+
* Resource: `tencentcloud_clb_listener_rule` add new argument `forward_type` to support backend protocol([#522](https://github.com/tencentcloudstack/terraform-provider-tencentcloud/issues/522)).
34+
* Resource: `tencentcloud_instance` add new argument `keep_image_login` to support keeping image login.
35+
* Resource: `tencentcloud_kubernetes_cluster` add new argument `extra_args` to support Kubelet.
36+
* Resource: `tencentcloud_kubernetes_scale_worker` add new argument `extra_args` to support Kubelet.
37+
* Resource: `tencentcloud_kubernetes_as_scaling_group` add new argument `extra_args` to support Kubelet.
38+
239
## 1.44.0 (September 25, 2020)
340

441
FEATURES:

examples/tencentcloud-clb/main.tf

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -131,6 +131,50 @@ resource "tencentcloud_clb_redirection" "redirection_http" {
131131
target_rule_id = tencentcloud_clb_listener_rule.rule_http_dst.id
132132
}
133133

134+
resource "tencentcloud_clb_instance" "clb_basic" {
135+
network_type = "OPEN"
136+
clb_name = "tf-clb-rule-basic"
137+
}
138+
139+
resource "tencentcloud_clb_listener" "listener_basic" {
140+
clb_id = tencentcloud_clb_instance.clb_basic.id
141+
port = 1
142+
protocol = "HTTP"
143+
listener_name = "listener_basic"
144+
}
145+
146+
resource "tencentcloud_clb_listener_rule" "rule_basic" {
147+
clb_id = tencentcloud_clb_instance.clb_basic.id
148+
listener_id = tencentcloud_clb_listener.listener_basic.id
149+
domain = "abc.com"
150+
url = "/"
151+
session_expire_time = 30
152+
scheduler = "WRR"
153+
target_type = "TARGETGROUP"
154+
}
155+
156+
resource "tencentcloud_clb_target_group" "test"{
157+
target_group_name = "test-target-keep-1"
158+
}
159+
160+
resource "tencentcloud_clb_target_group_instance_attachment" "test"{
161+
target_group_id = tencentcloud_clb_target_group.test.id
162+
bind_ip = "172.16.48.18"
163+
port = 222
164+
weight = 3
165+
}
166+
167+
resource "tencentcloud_clb_target_group_attachment" "group" {
168+
clb_id = tencentcloud_clb_instance.clb_basic.id
169+
listener_id = tencentcloud_clb_listener.listener_basic.id
170+
rule_id = tencentcloud_clb_listener_rule.rule_basic.id
171+
targrt_group_id = tencentcloud_clb_target_group.test.id
172+
}
173+
174+
data "tencentcloud_clb_target_groups" "target_group_info_id" {
175+
target_group_id = tencentcloud_clb_target_group.test.id
176+
}
177+
134178
data "tencentcloud_clb_instances" "instances" {
135179
clb_id = tencentcloud_clb_instance.example.id
136180
}

examples/tencentcloud-sqlserver/main.tf

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,15 @@ resource "tencentcloud_sqlserver_readonly_instance" "example" {
6060
force_upgrade = true
6161
}
6262

63+
resource "tencentcloud_sqlserver_publish_subscribe" "example" {
64+
publish_instance_id = tencentcloud_sqlserver_instance.example.id
65+
subscribe_instance_id = tencentcloud_sqlserver_instance.example_other.id
66+
publish_subscribe_name = "example"
67+
database_tuples {
68+
publish_database = tencentcloud_sqlserver_db.example.name
69+
}
70+
}
71+
6372

6473
data "tencentcloud_sqlserver_instances" "id_example" {
6574
id = tencentcloud_sqlserver_instance.example.id
@@ -97,3 +106,9 @@ data "tencentcloud_sqlserver_readonly_groups" "example" {
97106
master_instance_id = tencentcloud_sqlserver_instance.example.id
98107
}
99108

109+
data "tencentcloud_sqlserver_publish_subscribes" "publish_subscribes" {
110+
instance_id = tencentcloud_sqlserver_publish_subscribe.example.publish_instance_id
111+
pub_or_sub_instance_id = tencentcloud_sqlserver_publish_subscribe.example.subscribe_instance_id
112+
publish_subscribe_name = tencentcloud_sqlserver_publish_subscribe.example.publish_subscribe_name
113+
}
114+

examples/tencentcloud-vod/main.tf

Lines changed: 131 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,131 @@
1+
provider "tencentcloud" {
2+
region = "ap-guangzhou"
3+
}
4+
5+
resource "tencentcloud_vod_adaptive_dynamic_streaming_template" "foo" {
6+
format = "HLS"
7+
name = "tf-adaptive"
8+
drm_type = "SimpleAES"
9+
disable_higher_video_bitrate = false
10+
disable_higher_video_resolution = false
11+
comment = "test"
12+
13+
stream_info {
14+
video {
15+
codec = "libx265"
16+
fps = 4
17+
bitrate = 129
18+
resolution_adaptive = false
19+
width = 128
20+
height = 128
21+
fill_type = "stretch"
22+
}
23+
audio {
24+
codec = "libmp3lame"
25+
bitrate = 129
26+
sample_rate = 44100
27+
audio_channel = "dual"
28+
}
29+
remove_audio = false
30+
}
31+
stream_info {
32+
video {
33+
codec = "libx264"
34+
fps = 4
35+
bitrate = 256
36+
}
37+
audio {
38+
codec = "libfdk_aac"
39+
bitrate = 256
40+
sample_rate = 44100
41+
}
42+
remove_audio = true
43+
}
44+
}
45+
46+
resource "tencentcloud_vod_image_sprite_template" "foo" {
47+
sample_type = "Percent"
48+
sample_interval = 10
49+
row_count = 3
50+
column_count = 3
51+
name = "tf-sprite"
52+
comment = "test"
53+
fill_type = "stretch"
54+
width = 128
55+
height = 128
56+
resolution_adaptive = false
57+
}
58+
59+
resource "tencentcloud_vod_snapshot_by_time_offset_template" "foo" {
60+
name = "tf-snapshot"
61+
width = 130
62+
height = 128
63+
resolution_adaptive = false
64+
format = "png"
65+
comment = "test"
66+
fill_type = "white"
67+
}
68+
69+
resource "tencentcloud_vod_super_player_config" "foo" {
70+
name = "tf-super-player"
71+
drm_switch = true
72+
drm_streaming_info {
73+
simple_aes_definition = tencentcloud_vod_adaptive_dynamic_streaming_template.foo.id
74+
}
75+
image_sprite_definition = tencentcloud_vod_image_sprite_template.foo.id
76+
resolution_names {
77+
min_edge_length = 889
78+
name = "test1"
79+
}
80+
resolution_names {
81+
min_edge_length = 890
82+
name = "test2"
83+
}
84+
domain = "Default"
85+
scheme = "Default"
86+
comment = "test"
87+
}
88+
89+
resource "tencentcloud_vod_procedure_template" "foo" {
90+
name = "tf-procedure"
91+
comment = "test"
92+
media_process_task {
93+
adaptive_dynamic_streaming_task_list {
94+
definition = tencentcloud_vod_adaptive_dynamic_streaming_template.foo.id
95+
}
96+
snapshot_by_time_offset_task_list {
97+
definition = tencentcloud_vod_snapshot_by_time_offset_template.foo.id
98+
ext_time_offset_list = [
99+
"3.5s"
100+
]
101+
}
102+
image_sprite_task_list {
103+
definition = tencentcloud_vod_image_sprite_template.foo.id
104+
}
105+
}
106+
}
107+
108+
data "tencentcloud_vod_adaptive_dynamic_streaming_templates" "foo" {
109+
type = "Custom"
110+
definition = tencentcloud_vod_adaptive_dynamic_streaming_template.foo.id
111+
}
112+
113+
data "tencentcloud_vod_image_sprite_templates" "foo" {
114+
type = "Custom"
115+
definition = tencentcloud_vod_image_sprite_template.foo.id
116+
}
117+
118+
data "tencentcloud_vod_snapshot_by_time_offset_templates" "foo" {
119+
type = "Custom"
120+
definition = tencentcloud_vod_snapshot_by_time_offset_template.foo.id
121+
}
122+
123+
data "tencentcloud_vod_super_player_configs" "foo" {
124+
type = "Custom"
125+
name = tencentcloud_vod_super_player_config.foo.id
126+
}
127+
128+
data "tencentcloud_vod_procedure_templates" "foo" {
129+
type = "Custom"
130+
name = tencentcloud_vod_procedure_template.foo.id
131+
}
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
variable "availability_zone" {
2+
default = "ap-guangzhou-4"
3+
}

examples/tencentcloud-vod/version.tf

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
terraform {
2+
required_version = ">= 0.12"
3+
}

tencentcloud/connectivity/client.go

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ import (
3535
tag "github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/tag/v20180813"
3636
tcaplusdb "github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/tcaplusdb/v20190823"
3737
tke "github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/tke/v20180525"
38+
vod "github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/vod/v20180717"
3839
vpc "github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/vpc/v20170312"
3940
ssl "github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/wss/v20180426"
4041
)
@@ -74,6 +75,7 @@ type TencentCloudClient struct {
7475
ckafkaConn *ckafka.Client
7576
auditConn *audit.Client
7677
cynosConn *cynosdb.Client
78+
vodConn *vod.Client
7779
}
7880

7981
// NewClientProfile returns a new ClientProfile
@@ -473,3 +475,16 @@ func (me *TencentCloudClient) UseCynosdbClient() *cynosdb.Client {
473475

474476
return me.cynosConn
475477
}
478+
479+
// UseVodClient returns vod client for service
480+
func (me *TencentCloudClient) UseVodClient() *vod.Client {
481+
if me.vodConn != nil {
482+
return me.vodConn
483+
}
484+
485+
cpf := me.NewClientProfile(300)
486+
me.vodConn, _ = vod.NewClient(me.Credential, me.Region, cpf)
487+
me.vodConn.WithHttpTransport(&LogRoundTripper{})
488+
489+
return me.vodConn
490+
}

tencentcloud/data_source_tc_cam_policies.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,13 +53,13 @@ func dataSourceTencentCloudCamPolicies() *schema.Resource {
5353
Type: schema.TypeInt,
5454
Optional: true,
5555
ValidateFunc: validateAllowedIntValue([]int{1, 2}),
56-
Description: "Type of the policy strategy. 1 means customer strategy and 2 means preset strategy.",
56+
Description: "Type of the policy strategy. Valid values: 1, 2. 1 means customer strategy and 2 means preset strategy.",
5757
},
5858
"create_mode": {
5959
Type: schema.TypeInt,
6060
Optional: true,
6161
ValidateFunc: validateAllowedIntValue([]int{1, 2}),
62-
Description: "Mode of creation of policy strategy. 1 means policy was created with console, and 2 means it was created by strategies.",
62+
Description: "Mode of creation of policy strategy. Valid values: 1, 2. 1 means policy was created with console, and 2 means it was created by strategies.",
6363
},
6464
"result_output_file": {
6565
Type: schema.TypeString,

tencentcloud/data_source_tc_ccn_bandwidth_limits.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,6 @@ func dataSourceTencentCloudCcnBandwidthLimits() *schema.Resource {
4949
Optional: true,
5050
Description: "Used to save results.",
5151
},
52-
5352
// Computed values
5453
"limits": {
5554
Type: schema.TypeList,

tencentcloud/data_source_tc_cdn_domains.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,13 +48,13 @@ func dataSourceTencentCloudCdnDomains() *schema.Resource {
4848
Type: schema.TypeString,
4949
Optional: true,
5050
ValidateFunc: validateAllowedStringValue(CDN_ORIGIN_PULL_PROTOCOL),
51-
Description: "Origin-pull protocol configuration. The available value include `http`, `https` and `follow`.",
51+
Description: "Origin-pull protocol configuration. Valid values: `http`, `https` and `follow`.",
5252
},
5353
"https_switch": {
5454
Type: schema.TypeString,
5555
Optional: true,
5656
ValidateFunc: validateAllowedStringValue(CDN_HTTPS_SWITCH),
57-
Description: "HTTPS configuration. The available value include `on`, `off` and `processing`.",
57+
Description: "HTTPS configuration. Valid values: `on`, `off` and `processing`.",
5858
},
5959
"result_output_file": {
6060
Type: schema.TypeString,

0 commit comments

Comments
 (0)