Skip to content

Commit fde3557

Browse files
authored
Merge pull request #529 from brickzzhang/vod
[new datasources and resources for vod]
2 parents 79c8f44 + e011244 commit fde3557

File tree

44 files changed

+19766
-249
lines changed

Some content is hidden

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

44 files changed

+19766
-249
lines changed

CHANGELOG.md

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,17 @@
1-
## 1.44.1 (Unreleased)
1+
## 1.45.0 (Unreleased)
2+
3+
FEATURES:
4+
5+
* **New Resource**: `tencentcloud_vod_adaptive_dynamic_streaming_template`.
6+
* **New Resource**: `tencentcloud_vod_procedure_template`.
7+
* **New Resource**: `tencentcloud_vod_snapshot_by_time_offset_template`.
8+
* **New Resource**: `tencentcloud_vod_image_sprite_template`.
9+
* **New Resource**: `tencentcloud_vod_super_player_config`.
10+
* **New Data Source**: `tencentcloud_vod_adaptive_dynamic_streaming_templates`.
11+
* **New Data Source**: `tencentcloud_vod_image_sprite_templates`.
12+
* **New Data Source**: `tencentcloud_vod_procedure_templates`.
13+
* **New Data Source**: `tencentcloud_vod_snapshot_by_time_offset_templates`.
14+
* **New Data Source**: `tencentcloud_vod_super_player_configs`.
215

316
ENHANCEMENTS:
417

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+
}

0 commit comments

Comments
 (0)