/
externalKey.go
432 lines (372 loc) · 23.8 KB
/
externalKey.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
// Code generated by the Pulumi Terraform Bridge (tfgen) Tool DO NOT EDIT.
// *** WARNING: Do not edit by hand unless you're certain you know what you are doing! ***
package kms
import (
"context"
"reflect"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
// Manages a single-Region or multi-Region primary KMS key that uses external key material.
// To instead manage a single-Region or multi-Region primary KMS key where AWS automatically generates and potentially rotates key material, see the `kms.Key` resource.
//
// ## Example Usage
//
// ```go
// package main
//
// import (
//
// "github.com/pulumi/pulumi-aws/sdk/v5/go/aws/kms"
// "github.com/pulumi/pulumi/sdk/v3/go/pulumi"
//
// )
//
// func main() {
// pulumi.Run(func(ctx *pulumi.Context) error {
// _, err := kms.NewExternalKey(ctx, "example", &kms.ExternalKeyArgs{
// Description: pulumi.String("KMS EXTERNAL for AMI encryption"),
// })
// if err != nil {
// return err
// }
// return nil
// })
// }
//
// ```
//
// ## Import
//
// KMS External Keys can be imported using the `id`, e.g.,
//
// ```sh
//
// $ pulumi import aws:kms/externalKey:ExternalKey a arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab
//
// ```
type ExternalKey struct {
pulumi.CustomResourceState
// The Amazon Resource Name (ARN) of the key.
Arn pulumi.StringOutput `pulumi:"arn"`
// Specifies whether to disable the policy lockout check performed when creating or updating the key's policy. Setting this value to `true` increases the risk that the key becomes unmanageable. For more information, refer to the scenario in the [Default Key Policy](https://docs.aws.amazon.com/kms/latest/developerguide/key-policies.html#key-policy-default-allow-root-enable-iam) section in the AWS Key Management Service Developer Guide. Defaults to `false`.
BypassPolicyLockoutSafetyCheck pulumi.BoolPtrOutput `pulumi:"bypassPolicyLockoutSafetyCheck"`
// Duration in days after which the key is deleted after destruction of the resource. Must be between `7` and `30` days. Defaults to `30`.
DeletionWindowInDays pulumi.IntPtrOutput `pulumi:"deletionWindowInDays"`
// Description of the key.
Description pulumi.StringPtrOutput `pulumi:"description"`
// Specifies whether the key is enabled. Keys pending import can only be `false`. Imported keys default to `true` unless expired.
Enabled pulumi.BoolOutput `pulumi:"enabled"`
// Whether the key material expires. Empty when pending key material import, otherwise `KEY_MATERIAL_EXPIRES` or `KEY_MATERIAL_DOES_NOT_EXPIRE`.
ExpirationModel pulumi.StringOutput `pulumi:"expirationModel"`
// Base64 encoded 256-bit symmetric encryption key material to import. The CMK is permanently associated with this key material. The same key material can be reimported, but you cannot import different key material.
KeyMaterialBase64 pulumi.StringPtrOutput `pulumi:"keyMaterialBase64"`
// The state of the CMK.
KeyState pulumi.StringOutput `pulumi:"keyState"`
// The cryptographic operations for which you can use the CMK.
KeyUsage pulumi.StringOutput `pulumi:"keyUsage"`
// Indicates whether the KMS key is a multi-Region (`true`) or regional (`false`) key. Defaults to `false`.
MultiRegion pulumi.BoolOutput `pulumi:"multiRegion"`
// A key policy JSON document. If you do not provide a key policy, AWS KMS attaches a default key policy to the CMK.
Policy pulumi.StringOutput `pulumi:"policy"`
// A key-value map of tags to assign to the key. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
Tags pulumi.StringMapOutput `pulumi:"tags"`
// A map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block.
TagsAll pulumi.StringMapOutput `pulumi:"tagsAll"`
// Time at which the imported key material expires. When the key material expires, AWS KMS deletes the key material and the CMK becomes unusable. If not specified, key material does not expire. Valid values: [RFC3339 time string](https://tools.ietf.org/html/rfc3339#section-5.8) (`YYYY-MM-DDTHH:MM:SSZ`)
ValidTo pulumi.StringPtrOutput `pulumi:"validTo"`
}
// NewExternalKey registers a new resource with the given unique name, arguments, and options.
func NewExternalKey(ctx *pulumi.Context,
name string, args *ExternalKeyArgs, opts ...pulumi.ResourceOption) (*ExternalKey, error) {
if args == nil {
args = &ExternalKeyArgs{}
}
if args.KeyMaterialBase64 != nil {
args.KeyMaterialBase64 = pulumi.ToSecret(args.KeyMaterialBase64).(pulumi.StringPtrInput)
}
secrets := pulumi.AdditionalSecretOutputs([]string{
"keyMaterialBase64",
})
opts = append(opts, secrets)
var resource ExternalKey
err := ctx.RegisterResource("aws:kms/externalKey:ExternalKey", name, args, &resource, opts...)
if err != nil {
return nil, err
}
return &resource, nil
}
// GetExternalKey gets an existing ExternalKey resource's state with the given name, ID, and optional
// state properties that are used to uniquely qualify the lookup (nil if not required).
func GetExternalKey(ctx *pulumi.Context,
name string, id pulumi.IDInput, state *ExternalKeyState, opts ...pulumi.ResourceOption) (*ExternalKey, error) {
var resource ExternalKey
err := ctx.ReadResource("aws:kms/externalKey:ExternalKey", name, id, state, &resource, opts...)
if err != nil {
return nil, err
}
return &resource, nil
}
// Input properties used for looking up and filtering ExternalKey resources.
type externalKeyState struct {
// The Amazon Resource Name (ARN) of the key.
Arn *string `pulumi:"arn"`
// Specifies whether to disable the policy lockout check performed when creating or updating the key's policy. Setting this value to `true` increases the risk that the key becomes unmanageable. For more information, refer to the scenario in the [Default Key Policy](https://docs.aws.amazon.com/kms/latest/developerguide/key-policies.html#key-policy-default-allow-root-enable-iam) section in the AWS Key Management Service Developer Guide. Defaults to `false`.
BypassPolicyLockoutSafetyCheck *bool `pulumi:"bypassPolicyLockoutSafetyCheck"`
// Duration in days after which the key is deleted after destruction of the resource. Must be between `7` and `30` days. Defaults to `30`.
DeletionWindowInDays *int `pulumi:"deletionWindowInDays"`
// Description of the key.
Description *string `pulumi:"description"`
// Specifies whether the key is enabled. Keys pending import can only be `false`. Imported keys default to `true` unless expired.
Enabled *bool `pulumi:"enabled"`
// Whether the key material expires. Empty when pending key material import, otherwise `KEY_MATERIAL_EXPIRES` or `KEY_MATERIAL_DOES_NOT_EXPIRE`.
ExpirationModel *string `pulumi:"expirationModel"`
// Base64 encoded 256-bit symmetric encryption key material to import. The CMK is permanently associated with this key material. The same key material can be reimported, but you cannot import different key material.
KeyMaterialBase64 *string `pulumi:"keyMaterialBase64"`
// The state of the CMK.
KeyState *string `pulumi:"keyState"`
// The cryptographic operations for which you can use the CMK.
KeyUsage *string `pulumi:"keyUsage"`
// Indicates whether the KMS key is a multi-Region (`true`) or regional (`false`) key. Defaults to `false`.
MultiRegion *bool `pulumi:"multiRegion"`
// A key policy JSON document. If you do not provide a key policy, AWS KMS attaches a default key policy to the CMK.
Policy *string `pulumi:"policy"`
// A key-value map of tags to assign to the key. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
Tags map[string]string `pulumi:"tags"`
// A map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block.
TagsAll map[string]string `pulumi:"tagsAll"`
// Time at which the imported key material expires. When the key material expires, AWS KMS deletes the key material and the CMK becomes unusable. If not specified, key material does not expire. Valid values: [RFC3339 time string](https://tools.ietf.org/html/rfc3339#section-5.8) (`YYYY-MM-DDTHH:MM:SSZ`)
ValidTo *string `pulumi:"validTo"`
}
type ExternalKeyState struct {
// The Amazon Resource Name (ARN) of the key.
Arn pulumi.StringPtrInput
// Specifies whether to disable the policy lockout check performed when creating or updating the key's policy. Setting this value to `true` increases the risk that the key becomes unmanageable. For more information, refer to the scenario in the [Default Key Policy](https://docs.aws.amazon.com/kms/latest/developerguide/key-policies.html#key-policy-default-allow-root-enable-iam) section in the AWS Key Management Service Developer Guide. Defaults to `false`.
BypassPolicyLockoutSafetyCheck pulumi.BoolPtrInput
// Duration in days after which the key is deleted after destruction of the resource. Must be between `7` and `30` days. Defaults to `30`.
DeletionWindowInDays pulumi.IntPtrInput
// Description of the key.
Description pulumi.StringPtrInput
// Specifies whether the key is enabled. Keys pending import can only be `false`. Imported keys default to `true` unless expired.
Enabled pulumi.BoolPtrInput
// Whether the key material expires. Empty when pending key material import, otherwise `KEY_MATERIAL_EXPIRES` or `KEY_MATERIAL_DOES_NOT_EXPIRE`.
ExpirationModel pulumi.StringPtrInput
// Base64 encoded 256-bit symmetric encryption key material to import. The CMK is permanently associated with this key material. The same key material can be reimported, but you cannot import different key material.
KeyMaterialBase64 pulumi.StringPtrInput
// The state of the CMK.
KeyState pulumi.StringPtrInput
// The cryptographic operations for which you can use the CMK.
KeyUsage pulumi.StringPtrInput
// Indicates whether the KMS key is a multi-Region (`true`) or regional (`false`) key. Defaults to `false`.
MultiRegion pulumi.BoolPtrInput
// A key policy JSON document. If you do not provide a key policy, AWS KMS attaches a default key policy to the CMK.
Policy pulumi.StringPtrInput
// A key-value map of tags to assign to the key. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
Tags pulumi.StringMapInput
// A map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block.
TagsAll pulumi.StringMapInput
// Time at which the imported key material expires. When the key material expires, AWS KMS deletes the key material and the CMK becomes unusable. If not specified, key material does not expire. Valid values: [RFC3339 time string](https://tools.ietf.org/html/rfc3339#section-5.8) (`YYYY-MM-DDTHH:MM:SSZ`)
ValidTo pulumi.StringPtrInput
}
func (ExternalKeyState) ElementType() reflect.Type {
return reflect.TypeOf((*externalKeyState)(nil)).Elem()
}
type externalKeyArgs struct {
// Specifies whether to disable the policy lockout check performed when creating or updating the key's policy. Setting this value to `true` increases the risk that the key becomes unmanageable. For more information, refer to the scenario in the [Default Key Policy](https://docs.aws.amazon.com/kms/latest/developerguide/key-policies.html#key-policy-default-allow-root-enable-iam) section in the AWS Key Management Service Developer Guide. Defaults to `false`.
BypassPolicyLockoutSafetyCheck *bool `pulumi:"bypassPolicyLockoutSafetyCheck"`
// Duration in days after which the key is deleted after destruction of the resource. Must be between `7` and `30` days. Defaults to `30`.
DeletionWindowInDays *int `pulumi:"deletionWindowInDays"`
// Description of the key.
Description *string `pulumi:"description"`
// Specifies whether the key is enabled. Keys pending import can only be `false`. Imported keys default to `true` unless expired.
Enabled *bool `pulumi:"enabled"`
// Base64 encoded 256-bit symmetric encryption key material to import. The CMK is permanently associated with this key material. The same key material can be reimported, but you cannot import different key material.
KeyMaterialBase64 *string `pulumi:"keyMaterialBase64"`
// Indicates whether the KMS key is a multi-Region (`true`) or regional (`false`) key. Defaults to `false`.
MultiRegion *bool `pulumi:"multiRegion"`
// A key policy JSON document. If you do not provide a key policy, AWS KMS attaches a default key policy to the CMK.
Policy *string `pulumi:"policy"`
// A key-value map of tags to assign to the key. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
Tags map[string]string `pulumi:"tags"`
// Time at which the imported key material expires. When the key material expires, AWS KMS deletes the key material and the CMK becomes unusable. If not specified, key material does not expire. Valid values: [RFC3339 time string](https://tools.ietf.org/html/rfc3339#section-5.8) (`YYYY-MM-DDTHH:MM:SSZ`)
ValidTo *string `pulumi:"validTo"`
}
// The set of arguments for constructing a ExternalKey resource.
type ExternalKeyArgs struct {
// Specifies whether to disable the policy lockout check performed when creating or updating the key's policy. Setting this value to `true` increases the risk that the key becomes unmanageable. For more information, refer to the scenario in the [Default Key Policy](https://docs.aws.amazon.com/kms/latest/developerguide/key-policies.html#key-policy-default-allow-root-enable-iam) section in the AWS Key Management Service Developer Guide. Defaults to `false`.
BypassPolicyLockoutSafetyCheck pulumi.BoolPtrInput
// Duration in days after which the key is deleted after destruction of the resource. Must be between `7` and `30` days. Defaults to `30`.
DeletionWindowInDays pulumi.IntPtrInput
// Description of the key.
Description pulumi.StringPtrInput
// Specifies whether the key is enabled. Keys pending import can only be `false`. Imported keys default to `true` unless expired.
Enabled pulumi.BoolPtrInput
// Base64 encoded 256-bit symmetric encryption key material to import. The CMK is permanently associated with this key material. The same key material can be reimported, but you cannot import different key material.
KeyMaterialBase64 pulumi.StringPtrInput
// Indicates whether the KMS key is a multi-Region (`true`) or regional (`false`) key. Defaults to `false`.
MultiRegion pulumi.BoolPtrInput
// A key policy JSON document. If you do not provide a key policy, AWS KMS attaches a default key policy to the CMK.
Policy pulumi.StringPtrInput
// A key-value map of tags to assign to the key. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
Tags pulumi.StringMapInput
// Time at which the imported key material expires. When the key material expires, AWS KMS deletes the key material and the CMK becomes unusable. If not specified, key material does not expire. Valid values: [RFC3339 time string](https://tools.ietf.org/html/rfc3339#section-5.8) (`YYYY-MM-DDTHH:MM:SSZ`)
ValidTo pulumi.StringPtrInput
}
func (ExternalKeyArgs) ElementType() reflect.Type {
return reflect.TypeOf((*externalKeyArgs)(nil)).Elem()
}
type ExternalKeyInput interface {
pulumi.Input
ToExternalKeyOutput() ExternalKeyOutput
ToExternalKeyOutputWithContext(ctx context.Context) ExternalKeyOutput
}
func (*ExternalKey) ElementType() reflect.Type {
return reflect.TypeOf((**ExternalKey)(nil)).Elem()
}
func (i *ExternalKey) ToExternalKeyOutput() ExternalKeyOutput {
return i.ToExternalKeyOutputWithContext(context.Background())
}
func (i *ExternalKey) ToExternalKeyOutputWithContext(ctx context.Context) ExternalKeyOutput {
return pulumi.ToOutputWithContext(ctx, i).(ExternalKeyOutput)
}
// ExternalKeyArrayInput is an input type that accepts ExternalKeyArray and ExternalKeyArrayOutput values.
// You can construct a concrete instance of `ExternalKeyArrayInput` via:
//
// ExternalKeyArray{ ExternalKeyArgs{...} }
type ExternalKeyArrayInput interface {
pulumi.Input
ToExternalKeyArrayOutput() ExternalKeyArrayOutput
ToExternalKeyArrayOutputWithContext(context.Context) ExternalKeyArrayOutput
}
type ExternalKeyArray []ExternalKeyInput
func (ExternalKeyArray) ElementType() reflect.Type {
return reflect.TypeOf((*[]*ExternalKey)(nil)).Elem()
}
func (i ExternalKeyArray) ToExternalKeyArrayOutput() ExternalKeyArrayOutput {
return i.ToExternalKeyArrayOutputWithContext(context.Background())
}
func (i ExternalKeyArray) ToExternalKeyArrayOutputWithContext(ctx context.Context) ExternalKeyArrayOutput {
return pulumi.ToOutputWithContext(ctx, i).(ExternalKeyArrayOutput)
}
// ExternalKeyMapInput is an input type that accepts ExternalKeyMap and ExternalKeyMapOutput values.
// You can construct a concrete instance of `ExternalKeyMapInput` via:
//
// ExternalKeyMap{ "key": ExternalKeyArgs{...} }
type ExternalKeyMapInput interface {
pulumi.Input
ToExternalKeyMapOutput() ExternalKeyMapOutput
ToExternalKeyMapOutputWithContext(context.Context) ExternalKeyMapOutput
}
type ExternalKeyMap map[string]ExternalKeyInput
func (ExternalKeyMap) ElementType() reflect.Type {
return reflect.TypeOf((*map[string]*ExternalKey)(nil)).Elem()
}
func (i ExternalKeyMap) ToExternalKeyMapOutput() ExternalKeyMapOutput {
return i.ToExternalKeyMapOutputWithContext(context.Background())
}
func (i ExternalKeyMap) ToExternalKeyMapOutputWithContext(ctx context.Context) ExternalKeyMapOutput {
return pulumi.ToOutputWithContext(ctx, i).(ExternalKeyMapOutput)
}
type ExternalKeyOutput struct{ *pulumi.OutputState }
func (ExternalKeyOutput) ElementType() reflect.Type {
return reflect.TypeOf((**ExternalKey)(nil)).Elem()
}
func (o ExternalKeyOutput) ToExternalKeyOutput() ExternalKeyOutput {
return o
}
func (o ExternalKeyOutput) ToExternalKeyOutputWithContext(ctx context.Context) ExternalKeyOutput {
return o
}
// The Amazon Resource Name (ARN) of the key.
func (o ExternalKeyOutput) Arn() pulumi.StringOutput {
return o.ApplyT(func(v *ExternalKey) pulumi.StringOutput { return v.Arn }).(pulumi.StringOutput)
}
// Specifies whether to disable the policy lockout check performed when creating or updating the key's policy. Setting this value to `true` increases the risk that the key becomes unmanageable. For more information, refer to the scenario in the [Default Key Policy](https://docs.aws.amazon.com/kms/latest/developerguide/key-policies.html#key-policy-default-allow-root-enable-iam) section in the AWS Key Management Service Developer Guide. Defaults to `false`.
func (o ExternalKeyOutput) BypassPolicyLockoutSafetyCheck() pulumi.BoolPtrOutput {
return o.ApplyT(func(v *ExternalKey) pulumi.BoolPtrOutput { return v.BypassPolicyLockoutSafetyCheck }).(pulumi.BoolPtrOutput)
}
// Duration in days after which the key is deleted after destruction of the resource. Must be between `7` and `30` days. Defaults to `30`.
func (o ExternalKeyOutput) DeletionWindowInDays() pulumi.IntPtrOutput {
return o.ApplyT(func(v *ExternalKey) pulumi.IntPtrOutput { return v.DeletionWindowInDays }).(pulumi.IntPtrOutput)
}
// Description of the key.
func (o ExternalKeyOutput) Description() pulumi.StringPtrOutput {
return o.ApplyT(func(v *ExternalKey) pulumi.StringPtrOutput { return v.Description }).(pulumi.StringPtrOutput)
}
// Specifies whether the key is enabled. Keys pending import can only be `false`. Imported keys default to `true` unless expired.
func (o ExternalKeyOutput) Enabled() pulumi.BoolOutput {
return o.ApplyT(func(v *ExternalKey) pulumi.BoolOutput { return v.Enabled }).(pulumi.BoolOutput)
}
// Whether the key material expires. Empty when pending key material import, otherwise `KEY_MATERIAL_EXPIRES` or `KEY_MATERIAL_DOES_NOT_EXPIRE`.
func (o ExternalKeyOutput) ExpirationModel() pulumi.StringOutput {
return o.ApplyT(func(v *ExternalKey) pulumi.StringOutput { return v.ExpirationModel }).(pulumi.StringOutput)
}
// Base64 encoded 256-bit symmetric encryption key material to import. The CMK is permanently associated with this key material. The same key material can be reimported, but you cannot import different key material.
func (o ExternalKeyOutput) KeyMaterialBase64() pulumi.StringPtrOutput {
return o.ApplyT(func(v *ExternalKey) pulumi.StringPtrOutput { return v.KeyMaterialBase64 }).(pulumi.StringPtrOutput)
}
// The state of the CMK.
func (o ExternalKeyOutput) KeyState() pulumi.StringOutput {
return o.ApplyT(func(v *ExternalKey) pulumi.StringOutput { return v.KeyState }).(pulumi.StringOutput)
}
// The cryptographic operations for which you can use the CMK.
func (o ExternalKeyOutput) KeyUsage() pulumi.StringOutput {
return o.ApplyT(func(v *ExternalKey) pulumi.StringOutput { return v.KeyUsage }).(pulumi.StringOutput)
}
// Indicates whether the KMS key is a multi-Region (`true`) or regional (`false`) key. Defaults to `false`.
func (o ExternalKeyOutput) MultiRegion() pulumi.BoolOutput {
return o.ApplyT(func(v *ExternalKey) pulumi.BoolOutput { return v.MultiRegion }).(pulumi.BoolOutput)
}
// A key policy JSON document. If you do not provide a key policy, AWS KMS attaches a default key policy to the CMK.
func (o ExternalKeyOutput) Policy() pulumi.StringOutput {
return o.ApplyT(func(v *ExternalKey) pulumi.StringOutput { return v.Policy }).(pulumi.StringOutput)
}
// A key-value map of tags to assign to the key. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
func (o ExternalKeyOutput) Tags() pulumi.StringMapOutput {
return o.ApplyT(func(v *ExternalKey) pulumi.StringMapOutput { return v.Tags }).(pulumi.StringMapOutput)
}
// A map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block.
func (o ExternalKeyOutput) TagsAll() pulumi.StringMapOutput {
return o.ApplyT(func(v *ExternalKey) pulumi.StringMapOutput { return v.TagsAll }).(pulumi.StringMapOutput)
}
// Time at which the imported key material expires. When the key material expires, AWS KMS deletes the key material and the CMK becomes unusable. If not specified, key material does not expire. Valid values: [RFC3339 time string](https://tools.ietf.org/html/rfc3339#section-5.8) (`YYYY-MM-DDTHH:MM:SSZ`)
func (o ExternalKeyOutput) ValidTo() pulumi.StringPtrOutput {
return o.ApplyT(func(v *ExternalKey) pulumi.StringPtrOutput { return v.ValidTo }).(pulumi.StringPtrOutput)
}
type ExternalKeyArrayOutput struct{ *pulumi.OutputState }
func (ExternalKeyArrayOutput) ElementType() reflect.Type {
return reflect.TypeOf((*[]*ExternalKey)(nil)).Elem()
}
func (o ExternalKeyArrayOutput) ToExternalKeyArrayOutput() ExternalKeyArrayOutput {
return o
}
func (o ExternalKeyArrayOutput) ToExternalKeyArrayOutputWithContext(ctx context.Context) ExternalKeyArrayOutput {
return o
}
func (o ExternalKeyArrayOutput) Index(i pulumi.IntInput) ExternalKeyOutput {
return pulumi.All(o, i).ApplyT(func(vs []interface{}) *ExternalKey {
return vs[0].([]*ExternalKey)[vs[1].(int)]
}).(ExternalKeyOutput)
}
type ExternalKeyMapOutput struct{ *pulumi.OutputState }
func (ExternalKeyMapOutput) ElementType() reflect.Type {
return reflect.TypeOf((*map[string]*ExternalKey)(nil)).Elem()
}
func (o ExternalKeyMapOutput) ToExternalKeyMapOutput() ExternalKeyMapOutput {
return o
}
func (o ExternalKeyMapOutput) ToExternalKeyMapOutputWithContext(ctx context.Context) ExternalKeyMapOutput {
return o
}
func (o ExternalKeyMapOutput) MapIndex(k pulumi.StringInput) ExternalKeyOutput {
return pulumi.All(o, k).ApplyT(func(vs []interface{}) *ExternalKey {
return vs[0].(map[string]*ExternalKey)[vs[1].(string)]
}).(ExternalKeyOutput)
}
func init() {
pulumi.RegisterInputType(reflect.TypeOf((*ExternalKeyInput)(nil)).Elem(), &ExternalKey{})
pulumi.RegisterInputType(reflect.TypeOf((*ExternalKeyArrayInput)(nil)).Elem(), ExternalKeyArray{})
pulumi.RegisterInputType(reflect.TypeOf((*ExternalKeyMapInput)(nil)).Elem(), ExternalKeyMap{})
pulumi.RegisterOutputType(ExternalKeyOutput{})
pulumi.RegisterOutputType(ExternalKeyArrayOutput{})
pulumi.RegisterOutputType(ExternalKeyMapOutput{})
}