You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Description: "ID of the project to which the instance belongs.",
97
97
},
98
+
"kms_key_id": {
99
+
Type: schema.TypeString,
100
+
Optional: true,
101
+
ForceNew: true,
102
+
Computed: true,
103
+
Description: "Optional parameters. When purchasing an encryption disk, customize the key. When this parameter is passed in, the `encrypt` parameter need be set.",
104
+
},
98
105
"encrypt": {
99
106
Type: schema.TypeBool,
100
107
Optional: true,
101
108
ForceNew: true,
102
-
Description: "Indicates whether CBS is encrypted.",
109
+
Description: "Pass in this parameter to create an encrypted cloud disk.",
103
110
},
104
111
"tags": {
105
112
Type: schema.TypeMap,
@@ -156,7 +163,7 @@ func resourceTencentCloudCbsStorageCreate(d *schema.ResourceData, meta interface
Description: "ID of the project to which the instance belongs.",
82
82
},
83
+
"kms_key_id": {
84
+
Type: schema.TypeString,
85
+
Optional: true,
86
+
ForceNew: true,
87
+
Computed: true,
88
+
Description: "Optional parameters. When purchasing an encryption disk, customize the key. When this parameter is passed in, the `encrypt` parameter need be set.",
89
+
},
83
90
"encrypt": {
84
91
Type: schema.TypeBool,
85
92
Optional: true,
@@ -148,6 +155,10 @@ func resourceTencentCloudCbsStorageSetCreate(d *schema.ResourceData, meta interf
148
155
request.SnapshotId=helper.String(v.(string))
149
156
}
150
157
158
+
ifv, ok:=d.GetOk("kms_key_id"); ok {
159
+
request.KmsKeyId=helper.String(v.(string))
160
+
}
161
+
151
162
if_, ok:=d.GetOk("encrypt"); ok {
152
163
request.Encrypt=helper.String("ENCRYPT")
153
164
}
@@ -234,6 +245,10 @@ func resourceTencentCloudCbsStorageSetRead(d *schema.ResourceData, meta interfac
0 commit comments