github.com/pulumi/pulumi-aws/sdk/v6@v6.32.0/go/aws/cloudformation/stack.go (about) 1 // Code generated by the Pulumi Terraform Bridge (tfgen) Tool DO NOT EDIT. 2 // *** WARNING: Do not edit by hand unless you're certain you know what you are doing! *** 3 4 package cloudformation 5 6 import ( 7 "context" 8 "reflect" 9 10 "github.com/pulumi/pulumi-aws/sdk/v6/go/aws/internal" 11 "github.com/pulumi/pulumi/sdk/v3/go/pulumi" 12 ) 13 14 // Provides a CloudFormation Stack resource. 15 // 16 // ## Example Usage 17 // 18 // <!--Start PulumiCodeChooser --> 19 // ```go 20 // package main 21 // 22 // import ( 23 // 24 // "encoding/json" 25 // 26 // "github.com/pulumi/pulumi-aws/sdk/v6/go/aws/cloudformation" 27 // "github.com/pulumi/pulumi/sdk/v3/go/pulumi" 28 // 29 // ) 30 // 31 // func main() { 32 // pulumi.Run(func(ctx *pulumi.Context) error { 33 // tmpJSON0, err := json.Marshal(map[string]interface{}{ 34 // "Parameters": map[string]interface{}{ 35 // "VPCCidr": map[string]interface{}{ 36 // "Type": "String", 37 // "Default": "10.0.0.0/16", 38 // "Description": "Enter the CIDR block for the VPC. Default is 10.0.0.0/16.", 39 // }, 40 // }, 41 // "Resources": map[string]interface{}{ 42 // "myVpc": map[string]interface{}{ 43 // "Type": "AWS::EC2::VPC", 44 // "Properties": map[string]interface{}{ 45 // "CidrBlock": map[string]interface{}{ 46 // "Ref": "VPCCidr", 47 // }, 48 // "Tags": []map[string]interface{}{ 49 // map[string]interface{}{ 50 // "Key": "Name", 51 // "Value": "Primary_CF_VPC", 52 // }, 53 // }, 54 // }, 55 // }, 56 // }, 57 // }) 58 // if err != nil { 59 // return err 60 // } 61 // json0 := string(tmpJSON0) 62 // _, err = cloudformation.NewStack(ctx, "network", &cloudformation.StackArgs{ 63 // Name: pulumi.String("networking-stack"), 64 // Parameters: pulumi.StringMap{ 65 // "VPCCidr": pulumi.String("10.0.0.0/16"), 66 // }, 67 // TemplateBody: pulumi.String(json0), 68 // }) 69 // if err != nil { 70 // return err 71 // } 72 // return nil 73 // }) 74 // } 75 // 76 // ``` 77 // <!--End PulumiCodeChooser --> 78 // 79 // ## Import 80 // 81 // Using `pulumi import`, import Cloudformation Stacks using the `name`. For example: 82 // 83 // ```sh 84 // $ pulumi import aws:cloudformation/stack:Stack stack networking-stack 85 // ``` 86 type Stack struct { 87 pulumi.CustomResourceState 88 89 // A list of capabilities. 90 // Valid values: `CAPABILITY_IAM`, `CAPABILITY_NAMED_IAM`, or `CAPABILITY_AUTO_EXPAND` 91 Capabilities pulumi.StringArrayOutput `pulumi:"capabilities"` 92 // Set to true to disable rollback of the stack if stack creation failed. 93 // Conflicts with `onFailure`. 94 DisableRollback pulumi.BoolPtrOutput `pulumi:"disableRollback"` 95 // The ARN of an IAM role that AWS CloudFormation assumes to create the stack. If you don't specify a value, AWS CloudFormation uses the role that was previously associated with the stack. If no role is available, AWS CloudFormation uses a temporary session that is generated from your user credentials. 96 IamRoleArn pulumi.StringPtrOutput `pulumi:"iamRoleArn"` 97 // Stack name. 98 Name pulumi.StringOutput `pulumi:"name"` 99 // A list of SNS topic ARNs to publish stack related events. 100 NotificationArns pulumi.StringArrayOutput `pulumi:"notificationArns"` 101 // Action to be taken if stack creation fails. This must be 102 // one of: `DO_NOTHING`, `ROLLBACK`, or `DELETE`. Conflicts with `disableRollback`. 103 OnFailure pulumi.StringPtrOutput `pulumi:"onFailure"` 104 // A map of outputs from the stack. 105 Outputs pulumi.StringMapOutput `pulumi:"outputs"` 106 // A map of Parameter structures that specify input parameters for the stack. 107 Parameters pulumi.StringMapOutput `pulumi:"parameters"` 108 // Structure containing the stack policy body. 109 // Conflicts w/ `policyUrl`. 110 PolicyBody pulumi.StringOutput `pulumi:"policyBody"` 111 // Location of a file containing the stack policy. 112 // Conflicts w/ `policyBody`. 113 PolicyUrl pulumi.StringPtrOutput `pulumi:"policyUrl"` 114 // Map of resource tags to associate with this stack. .If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level. 115 Tags pulumi.StringMapOutput `pulumi:"tags"` 116 // A map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block. 117 // 118 // Deprecated: Please use `tags` instead. 119 TagsAll pulumi.StringMapOutput `pulumi:"tagsAll"` 120 // Structure containing the template body (max size: 51,200 bytes). 121 TemplateBody pulumi.StringOutput `pulumi:"templateBody"` 122 // Location of a file containing the template body (max size: 460,800 bytes). 123 TemplateUrl pulumi.StringPtrOutput `pulumi:"templateUrl"` 124 // The amount of time that can pass before the stack status becomes `CREATE_FAILED`. 125 TimeoutInMinutes pulumi.IntPtrOutput `pulumi:"timeoutInMinutes"` 126 } 127 128 // NewStack registers a new resource with the given unique name, arguments, and options. 129 func NewStack(ctx *pulumi.Context, 130 name string, args *StackArgs, opts ...pulumi.ResourceOption) (*Stack, error) { 131 if args == nil { 132 args = &StackArgs{} 133 } 134 135 opts = internal.PkgResourceDefaultOpts(opts) 136 var resource Stack 137 err := ctx.RegisterResource("aws:cloudformation/stack:Stack", name, args, &resource, opts...) 138 if err != nil { 139 return nil, err 140 } 141 return &resource, nil 142 } 143 144 // GetStack gets an existing Stack resource's state with the given name, ID, and optional 145 // state properties that are used to uniquely qualify the lookup (nil if not required). 146 func GetStack(ctx *pulumi.Context, 147 name string, id pulumi.IDInput, state *StackState, opts ...pulumi.ResourceOption) (*Stack, error) { 148 var resource Stack 149 err := ctx.ReadResource("aws:cloudformation/stack:Stack", name, id, state, &resource, opts...) 150 if err != nil { 151 return nil, err 152 } 153 return &resource, nil 154 } 155 156 // Input properties used for looking up and filtering Stack resources. 157 type stackState struct { 158 // A list of capabilities. 159 // Valid values: `CAPABILITY_IAM`, `CAPABILITY_NAMED_IAM`, or `CAPABILITY_AUTO_EXPAND` 160 Capabilities []string `pulumi:"capabilities"` 161 // Set to true to disable rollback of the stack if stack creation failed. 162 // Conflicts with `onFailure`. 163 DisableRollback *bool `pulumi:"disableRollback"` 164 // The ARN of an IAM role that AWS CloudFormation assumes to create the stack. If you don't specify a value, AWS CloudFormation uses the role that was previously associated with the stack. If no role is available, AWS CloudFormation uses a temporary session that is generated from your user credentials. 165 IamRoleArn *string `pulumi:"iamRoleArn"` 166 // Stack name. 167 Name *string `pulumi:"name"` 168 // A list of SNS topic ARNs to publish stack related events. 169 NotificationArns []string `pulumi:"notificationArns"` 170 // Action to be taken if stack creation fails. This must be 171 // one of: `DO_NOTHING`, `ROLLBACK`, or `DELETE`. Conflicts with `disableRollback`. 172 OnFailure *string `pulumi:"onFailure"` 173 // A map of outputs from the stack. 174 Outputs map[string]string `pulumi:"outputs"` 175 // A map of Parameter structures that specify input parameters for the stack. 176 Parameters map[string]string `pulumi:"parameters"` 177 // Structure containing the stack policy body. 178 // Conflicts w/ `policyUrl`. 179 PolicyBody *string `pulumi:"policyBody"` 180 // Location of a file containing the stack policy. 181 // Conflicts w/ `policyBody`. 182 PolicyUrl *string `pulumi:"policyUrl"` 183 // Map of resource tags to associate with this stack. .If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level. 184 Tags map[string]string `pulumi:"tags"` 185 // A map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block. 186 // 187 // Deprecated: Please use `tags` instead. 188 TagsAll map[string]string `pulumi:"tagsAll"` 189 // Structure containing the template body (max size: 51,200 bytes). 190 TemplateBody *string `pulumi:"templateBody"` 191 // Location of a file containing the template body (max size: 460,800 bytes). 192 TemplateUrl *string `pulumi:"templateUrl"` 193 // The amount of time that can pass before the stack status becomes `CREATE_FAILED`. 194 TimeoutInMinutes *int `pulumi:"timeoutInMinutes"` 195 } 196 197 type StackState struct { 198 // A list of capabilities. 199 // Valid values: `CAPABILITY_IAM`, `CAPABILITY_NAMED_IAM`, or `CAPABILITY_AUTO_EXPAND` 200 Capabilities pulumi.StringArrayInput 201 // Set to true to disable rollback of the stack if stack creation failed. 202 // Conflicts with `onFailure`. 203 DisableRollback pulumi.BoolPtrInput 204 // The ARN of an IAM role that AWS CloudFormation assumes to create the stack. If you don't specify a value, AWS CloudFormation uses the role that was previously associated with the stack. If no role is available, AWS CloudFormation uses a temporary session that is generated from your user credentials. 205 IamRoleArn pulumi.StringPtrInput 206 // Stack name. 207 Name pulumi.StringPtrInput 208 // A list of SNS topic ARNs to publish stack related events. 209 NotificationArns pulumi.StringArrayInput 210 // Action to be taken if stack creation fails. This must be 211 // one of: `DO_NOTHING`, `ROLLBACK`, or `DELETE`. Conflicts with `disableRollback`. 212 OnFailure pulumi.StringPtrInput 213 // A map of outputs from the stack. 214 Outputs pulumi.StringMapInput 215 // A map of Parameter structures that specify input parameters for the stack. 216 Parameters pulumi.StringMapInput 217 // Structure containing the stack policy body. 218 // Conflicts w/ `policyUrl`. 219 PolicyBody pulumi.StringPtrInput 220 // Location of a file containing the stack policy. 221 // Conflicts w/ `policyBody`. 222 PolicyUrl pulumi.StringPtrInput 223 // Map of resource tags to associate with this stack. .If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level. 224 Tags pulumi.StringMapInput 225 // A map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block. 226 // 227 // Deprecated: Please use `tags` instead. 228 TagsAll pulumi.StringMapInput 229 // Structure containing the template body (max size: 51,200 bytes). 230 TemplateBody pulumi.StringPtrInput 231 // Location of a file containing the template body (max size: 460,800 bytes). 232 TemplateUrl pulumi.StringPtrInput 233 // The amount of time that can pass before the stack status becomes `CREATE_FAILED`. 234 TimeoutInMinutes pulumi.IntPtrInput 235 } 236 237 func (StackState) ElementType() reflect.Type { 238 return reflect.TypeOf((*stackState)(nil)).Elem() 239 } 240 241 type stackArgs struct { 242 // A list of capabilities. 243 // Valid values: `CAPABILITY_IAM`, `CAPABILITY_NAMED_IAM`, or `CAPABILITY_AUTO_EXPAND` 244 Capabilities []string `pulumi:"capabilities"` 245 // Set to true to disable rollback of the stack if stack creation failed. 246 // Conflicts with `onFailure`. 247 DisableRollback *bool `pulumi:"disableRollback"` 248 // The ARN of an IAM role that AWS CloudFormation assumes to create the stack. If you don't specify a value, AWS CloudFormation uses the role that was previously associated with the stack. If no role is available, AWS CloudFormation uses a temporary session that is generated from your user credentials. 249 IamRoleArn *string `pulumi:"iamRoleArn"` 250 // Stack name. 251 Name *string `pulumi:"name"` 252 // A list of SNS topic ARNs to publish stack related events. 253 NotificationArns []string `pulumi:"notificationArns"` 254 // Action to be taken if stack creation fails. This must be 255 // one of: `DO_NOTHING`, `ROLLBACK`, or `DELETE`. Conflicts with `disableRollback`. 256 OnFailure *string `pulumi:"onFailure"` 257 // A map of Parameter structures that specify input parameters for the stack. 258 Parameters map[string]string `pulumi:"parameters"` 259 // Structure containing the stack policy body. 260 // Conflicts w/ `policyUrl`. 261 PolicyBody *string `pulumi:"policyBody"` 262 // Location of a file containing the stack policy. 263 // Conflicts w/ `policyBody`. 264 PolicyUrl *string `pulumi:"policyUrl"` 265 // Map of resource tags to associate with this stack. .If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level. 266 Tags map[string]string `pulumi:"tags"` 267 // Structure containing the template body (max size: 51,200 bytes). 268 TemplateBody *string `pulumi:"templateBody"` 269 // Location of a file containing the template body (max size: 460,800 bytes). 270 TemplateUrl *string `pulumi:"templateUrl"` 271 // The amount of time that can pass before the stack status becomes `CREATE_FAILED`. 272 TimeoutInMinutes *int `pulumi:"timeoutInMinutes"` 273 } 274 275 // The set of arguments for constructing a Stack resource. 276 type StackArgs struct { 277 // A list of capabilities. 278 // Valid values: `CAPABILITY_IAM`, `CAPABILITY_NAMED_IAM`, or `CAPABILITY_AUTO_EXPAND` 279 Capabilities pulumi.StringArrayInput 280 // Set to true to disable rollback of the stack if stack creation failed. 281 // Conflicts with `onFailure`. 282 DisableRollback pulumi.BoolPtrInput 283 // The ARN of an IAM role that AWS CloudFormation assumes to create the stack. If you don't specify a value, AWS CloudFormation uses the role that was previously associated with the stack. If no role is available, AWS CloudFormation uses a temporary session that is generated from your user credentials. 284 IamRoleArn pulumi.StringPtrInput 285 // Stack name. 286 Name pulumi.StringPtrInput 287 // A list of SNS topic ARNs to publish stack related events. 288 NotificationArns pulumi.StringArrayInput 289 // Action to be taken if stack creation fails. This must be 290 // one of: `DO_NOTHING`, `ROLLBACK`, or `DELETE`. Conflicts with `disableRollback`. 291 OnFailure pulumi.StringPtrInput 292 // A map of Parameter structures that specify input parameters for the stack. 293 Parameters pulumi.StringMapInput 294 // Structure containing the stack policy body. 295 // Conflicts w/ `policyUrl`. 296 PolicyBody pulumi.StringPtrInput 297 // Location of a file containing the stack policy. 298 // Conflicts w/ `policyBody`. 299 PolicyUrl pulumi.StringPtrInput 300 // Map of resource tags to associate with this stack. .If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level. 301 Tags pulumi.StringMapInput 302 // Structure containing the template body (max size: 51,200 bytes). 303 TemplateBody pulumi.StringPtrInput 304 // Location of a file containing the template body (max size: 460,800 bytes). 305 TemplateUrl pulumi.StringPtrInput 306 // The amount of time that can pass before the stack status becomes `CREATE_FAILED`. 307 TimeoutInMinutes pulumi.IntPtrInput 308 } 309 310 func (StackArgs) ElementType() reflect.Type { 311 return reflect.TypeOf((*stackArgs)(nil)).Elem() 312 } 313 314 type StackInput interface { 315 pulumi.Input 316 317 ToStackOutput() StackOutput 318 ToStackOutputWithContext(ctx context.Context) StackOutput 319 } 320 321 func (*Stack) ElementType() reflect.Type { 322 return reflect.TypeOf((**Stack)(nil)).Elem() 323 } 324 325 func (i *Stack) ToStackOutput() StackOutput { 326 return i.ToStackOutputWithContext(context.Background()) 327 } 328 329 func (i *Stack) ToStackOutputWithContext(ctx context.Context) StackOutput { 330 return pulumi.ToOutputWithContext(ctx, i).(StackOutput) 331 } 332 333 // StackArrayInput is an input type that accepts StackArray and StackArrayOutput values. 334 // You can construct a concrete instance of `StackArrayInput` via: 335 // 336 // StackArray{ StackArgs{...} } 337 type StackArrayInput interface { 338 pulumi.Input 339 340 ToStackArrayOutput() StackArrayOutput 341 ToStackArrayOutputWithContext(context.Context) StackArrayOutput 342 } 343 344 type StackArray []StackInput 345 346 func (StackArray) ElementType() reflect.Type { 347 return reflect.TypeOf((*[]*Stack)(nil)).Elem() 348 } 349 350 func (i StackArray) ToStackArrayOutput() StackArrayOutput { 351 return i.ToStackArrayOutputWithContext(context.Background()) 352 } 353 354 func (i StackArray) ToStackArrayOutputWithContext(ctx context.Context) StackArrayOutput { 355 return pulumi.ToOutputWithContext(ctx, i).(StackArrayOutput) 356 } 357 358 // StackMapInput is an input type that accepts StackMap and StackMapOutput values. 359 // You can construct a concrete instance of `StackMapInput` via: 360 // 361 // StackMap{ "key": StackArgs{...} } 362 type StackMapInput interface { 363 pulumi.Input 364 365 ToStackMapOutput() StackMapOutput 366 ToStackMapOutputWithContext(context.Context) StackMapOutput 367 } 368 369 type StackMap map[string]StackInput 370 371 func (StackMap) ElementType() reflect.Type { 372 return reflect.TypeOf((*map[string]*Stack)(nil)).Elem() 373 } 374 375 func (i StackMap) ToStackMapOutput() StackMapOutput { 376 return i.ToStackMapOutputWithContext(context.Background()) 377 } 378 379 func (i StackMap) ToStackMapOutputWithContext(ctx context.Context) StackMapOutput { 380 return pulumi.ToOutputWithContext(ctx, i).(StackMapOutput) 381 } 382 383 type StackOutput struct{ *pulumi.OutputState } 384 385 func (StackOutput) ElementType() reflect.Type { 386 return reflect.TypeOf((**Stack)(nil)).Elem() 387 } 388 389 func (o StackOutput) ToStackOutput() StackOutput { 390 return o 391 } 392 393 func (o StackOutput) ToStackOutputWithContext(ctx context.Context) StackOutput { 394 return o 395 } 396 397 // A list of capabilities. 398 // Valid values: `CAPABILITY_IAM`, `CAPABILITY_NAMED_IAM`, or `CAPABILITY_AUTO_EXPAND` 399 func (o StackOutput) Capabilities() pulumi.StringArrayOutput { 400 return o.ApplyT(func(v *Stack) pulumi.StringArrayOutput { return v.Capabilities }).(pulumi.StringArrayOutput) 401 } 402 403 // Set to true to disable rollback of the stack if stack creation failed. 404 // Conflicts with `onFailure`. 405 func (o StackOutput) DisableRollback() pulumi.BoolPtrOutput { 406 return o.ApplyT(func(v *Stack) pulumi.BoolPtrOutput { return v.DisableRollback }).(pulumi.BoolPtrOutput) 407 } 408 409 // The ARN of an IAM role that AWS CloudFormation assumes to create the stack. If you don't specify a value, AWS CloudFormation uses the role that was previously associated with the stack. If no role is available, AWS CloudFormation uses a temporary session that is generated from your user credentials. 410 func (o StackOutput) IamRoleArn() pulumi.StringPtrOutput { 411 return o.ApplyT(func(v *Stack) pulumi.StringPtrOutput { return v.IamRoleArn }).(pulumi.StringPtrOutput) 412 } 413 414 // Stack name. 415 func (o StackOutput) Name() pulumi.StringOutput { 416 return o.ApplyT(func(v *Stack) pulumi.StringOutput { return v.Name }).(pulumi.StringOutput) 417 } 418 419 // A list of SNS topic ARNs to publish stack related events. 420 func (o StackOutput) NotificationArns() pulumi.StringArrayOutput { 421 return o.ApplyT(func(v *Stack) pulumi.StringArrayOutput { return v.NotificationArns }).(pulumi.StringArrayOutput) 422 } 423 424 // Action to be taken if stack creation fails. This must be 425 // one of: `DO_NOTHING`, `ROLLBACK`, or `DELETE`. Conflicts with `disableRollback`. 426 func (o StackOutput) OnFailure() pulumi.StringPtrOutput { 427 return o.ApplyT(func(v *Stack) pulumi.StringPtrOutput { return v.OnFailure }).(pulumi.StringPtrOutput) 428 } 429 430 // A map of outputs from the stack. 431 func (o StackOutput) Outputs() pulumi.StringMapOutput { 432 return o.ApplyT(func(v *Stack) pulumi.StringMapOutput { return v.Outputs }).(pulumi.StringMapOutput) 433 } 434 435 // A map of Parameter structures that specify input parameters for the stack. 436 func (o StackOutput) Parameters() pulumi.StringMapOutput { 437 return o.ApplyT(func(v *Stack) pulumi.StringMapOutput { return v.Parameters }).(pulumi.StringMapOutput) 438 } 439 440 // Structure containing the stack policy body. 441 // Conflicts w/ `policyUrl`. 442 func (o StackOutput) PolicyBody() pulumi.StringOutput { 443 return o.ApplyT(func(v *Stack) pulumi.StringOutput { return v.PolicyBody }).(pulumi.StringOutput) 444 } 445 446 // Location of a file containing the stack policy. 447 // Conflicts w/ `policyBody`. 448 func (o StackOutput) PolicyUrl() pulumi.StringPtrOutput { 449 return o.ApplyT(func(v *Stack) pulumi.StringPtrOutput { return v.PolicyUrl }).(pulumi.StringPtrOutput) 450 } 451 452 // Map of resource tags to associate with this stack. .If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level. 453 func (o StackOutput) Tags() pulumi.StringMapOutput { 454 return o.ApplyT(func(v *Stack) pulumi.StringMapOutput { return v.Tags }).(pulumi.StringMapOutput) 455 } 456 457 // A map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block. 458 // 459 // Deprecated: Please use `tags` instead. 460 func (o StackOutput) TagsAll() pulumi.StringMapOutput { 461 return o.ApplyT(func(v *Stack) pulumi.StringMapOutput { return v.TagsAll }).(pulumi.StringMapOutput) 462 } 463 464 // Structure containing the template body (max size: 51,200 bytes). 465 func (o StackOutput) TemplateBody() pulumi.StringOutput { 466 return o.ApplyT(func(v *Stack) pulumi.StringOutput { return v.TemplateBody }).(pulumi.StringOutput) 467 } 468 469 // Location of a file containing the template body (max size: 460,800 bytes). 470 func (o StackOutput) TemplateUrl() pulumi.StringPtrOutput { 471 return o.ApplyT(func(v *Stack) pulumi.StringPtrOutput { return v.TemplateUrl }).(pulumi.StringPtrOutput) 472 } 473 474 // The amount of time that can pass before the stack status becomes `CREATE_FAILED`. 475 func (o StackOutput) TimeoutInMinutes() pulumi.IntPtrOutput { 476 return o.ApplyT(func(v *Stack) pulumi.IntPtrOutput { return v.TimeoutInMinutes }).(pulumi.IntPtrOutput) 477 } 478 479 type StackArrayOutput struct{ *pulumi.OutputState } 480 481 func (StackArrayOutput) ElementType() reflect.Type { 482 return reflect.TypeOf((*[]*Stack)(nil)).Elem() 483 } 484 485 func (o StackArrayOutput) ToStackArrayOutput() StackArrayOutput { 486 return o 487 } 488 489 func (o StackArrayOutput) ToStackArrayOutputWithContext(ctx context.Context) StackArrayOutput { 490 return o 491 } 492 493 func (o StackArrayOutput) Index(i pulumi.IntInput) StackOutput { 494 return pulumi.All(o, i).ApplyT(func(vs []interface{}) *Stack { 495 return vs[0].([]*Stack)[vs[1].(int)] 496 }).(StackOutput) 497 } 498 499 type StackMapOutput struct{ *pulumi.OutputState } 500 501 func (StackMapOutput) ElementType() reflect.Type { 502 return reflect.TypeOf((*map[string]*Stack)(nil)).Elem() 503 } 504 505 func (o StackMapOutput) ToStackMapOutput() StackMapOutput { 506 return o 507 } 508 509 func (o StackMapOutput) ToStackMapOutputWithContext(ctx context.Context) StackMapOutput { 510 return o 511 } 512 513 func (o StackMapOutput) MapIndex(k pulumi.StringInput) StackOutput { 514 return pulumi.All(o, k).ApplyT(func(vs []interface{}) *Stack { 515 return vs[0].(map[string]*Stack)[vs[1].(string)] 516 }).(StackOutput) 517 } 518 519 func init() { 520 pulumi.RegisterInputType(reflect.TypeOf((*StackInput)(nil)).Elem(), &Stack{}) 521 pulumi.RegisterInputType(reflect.TypeOf((*StackArrayInput)(nil)).Elem(), StackArray{}) 522 pulumi.RegisterInputType(reflect.TypeOf((*StackMapInput)(nil)).Elem(), StackMap{}) 523 pulumi.RegisterOutputType(StackOutput{}) 524 pulumi.RegisterOutputType(StackArrayOutput{}) 525 pulumi.RegisterOutputType(StackMapOutput{}) 526 }