« blib/lib/Paws/CloudFormation/TypeVersionSummary.pm
↑ Summary
blib/lib/Paws/CloudFormation/UpdateStackInstances.pm »
| 1 | |||
| 2 | package Paws::CloudFormation::UpdateStack; | ||
| 3 | use Moose; | ||
| 4 | has Capabilities => (is => 'ro', isa => 'ArrayRef[Str|Undef]'); | ||
| 5 | has ClientRequestToken => (is => 'ro', isa => 'Str'); | ||
| 6 | has NotificationARNs => (is => 'ro', isa => 'ArrayRef[Str|Undef]'); | ||
| 7 | has Parameters => (is => 'ro', isa => 'ArrayRef[Paws::CloudFormation::Parameter]'); | ||
| 8 | has ResourceTypes => (is => 'ro', isa => 'ArrayRef[Str|Undef]'); | ||
| 9 | has RoleARN => (is => 'ro', isa => 'Str'); | ||
| 10 | has RollbackConfiguration => (is => 'ro', isa => 'Paws::CloudFormation::RollbackConfiguration'); | ||
| 11 | has StackName => (is => 'ro', isa => 'Str', required => 1); | ||
| 12 | has StackPolicyBody => (is => 'ro', isa => 'Str'); | ||
| 13 | has StackPolicyDuringUpdateBody => (is => 'ro', isa => 'Str'); | ||
| 14 | has StackPolicyDuringUpdateURL => (is => 'ro', isa => 'Str'); | ||
| 15 | has StackPolicyURL => (is => 'ro', isa => 'Str'); | ||
| 16 | has Tags => (is => 'ro', isa => 'ArrayRef[Paws::CloudFormation::Tag]'); | ||
| 17 | has TemplateBody => (is => 'ro', isa => 'Str'); | ||
| 18 | has TemplateURL => (is => 'ro', isa => 'Str'); | ||
| 19 | has UsePreviousTemplate => (is => 'ro', isa => 'Bool'); | ||
| 20 | |||
| 21 | use MooseX::ClassAttribute; | ||
| 22 | |||
| 23 | class_has _api_call => (isa => 'Str', is => 'ro', default => 'UpdateStack'); | ||
| 24 | class_has _returns => (isa => 'Str', is => 'ro', default => 'Paws::CloudFormation::UpdateStackOutput'); | ||
| 25 | class_has _result_key => (isa => 'Str', is => 'ro', default => 'UpdateStackResult'); | ||
| 26 | 1; | ||
| 27 | |||
| 28 | ### main pod documentation begin ### | ||
| 29 | |||
| 30 | =head1 NAME | ||
| 31 | |||
| 32 | Paws::CloudFormation::UpdateStack - Arguments for method UpdateStack on L<Paws::CloudFormation> | ||
| 33 | |||
| 34 | =head1 DESCRIPTION | ||
| 35 | |||
| 36 | This class represents the parameters used for calling the method UpdateStack on the | ||
| 37 | L<AWS CloudFormation|Paws::CloudFormation> service. Use the attributes of this class | ||
| 38 | as arguments to method UpdateStack. | ||
| 39 | |||
| 40 | You shouldn't make instances of this class. Each attribute should be used as a named argument in the call to UpdateStack. | ||
| 41 | |||
| 42 | =head1 SYNOPSIS | ||
| 43 | |||
| 44 | my $cloudformation = Paws->service('CloudFormation'); | ||
| 45 | my $UpdateStackOutput = $cloudformation->UpdateStack( | ||
| 46 | StackName => 'MyStackName', | ||
| 47 | Capabilities => [ | ||
| 48 | 'CAPABILITY_IAM', | ||
| 49 | ... # values: CAPABILITY_IAM, CAPABILITY_NAMED_IAM, CAPABILITY_AUTO_EXPAND | ||
| 50 | ], # OPTIONAL | ||
| 51 | ClientRequestToken => 'MyClientRequestToken', # OPTIONAL | ||
| 52 | NotificationARNs => [ 'MyNotificationARN', ... ], # OPTIONAL | ||
| 53 | Parameters => [ | ||
| 54 | { | ||
| 55 | ParameterKey => 'MyParameterKey', # OPTIONAL | ||
| 56 | ParameterValue => 'MyParameterValue', # OPTIONAL | ||
| 57 | ResolvedValue => 'MyParameterValue', # OPTIONAL | ||
| 58 | UsePreviousValue => 1, # OPTIONAL | ||
| 59 | }, | ||
| 60 | ... | ||
| 61 | ], # OPTIONAL | ||
| 62 | ResourceTypes => [ | ||
| 63 | 'MyResourceType', ... # min: 1, max: 256 | ||
| 64 | ], # OPTIONAL | ||
| 65 | RoleARN => 'MyRoleARN', # OPTIONAL | ||
| 66 | RollbackConfiguration => { | ||
| 67 | MonitoringTimeInMinutes => 1, # max: 180; OPTIONAL | ||
| 68 | RollbackTriggers => [ | ||
| 69 | { | ||
| 70 | Arn => 'MyArn', | ||
| 71 | Type => 'MyType', | ||
| 72 | |||
| 73 | }, | ||
| 74 | ... | ||
| 75 | ], # max: 5; OPTIONAL | ||
| 76 | }, # OPTIONAL | ||
| 77 | StackPolicyBody => 'MyStackPolicyBody', # OPTIONAL | ||
| 78 | StackPolicyDuringUpdateBody => 'MyStackPolicyDuringUpdateBody', # OPTIONAL | ||
| 79 | StackPolicyDuringUpdateURL => 'MyStackPolicyDuringUpdateURL', # OPTIONAL | ||
| 80 | StackPolicyURL => 'MyStackPolicyURL', # OPTIONAL | ||
| 81 | Tags => [ | ||
| 82 | { | ||
| 83 | Key => 'MyTagKey', # min: 1, max: 128 | ||
| 84 | Value => 'MyTagValue', # min: 1, max: 256 | ||
| 85 | |||
| 86 | }, | ||
| 87 | ... | ||
| 88 | ], # OPTIONAL | ||
| 89 | TemplateBody => 'MyTemplateBody', # OPTIONAL | ||
| 90 | TemplateURL => 'MyTemplateURL', # OPTIONAL | ||
| 91 | UsePreviousTemplate => 1, # OPTIONAL | ||
| 92 | ); | ||
| 93 | |||
| 94 | # Results: | ||
| 95 | my $StackId = $UpdateStackOutput->StackId; | ||
| 96 | |||
| 97 | # Returns a L<Paws::CloudFormation::UpdateStackOutput> object. | ||
| 98 | |||
| 99 | Values for attributes that are native types (Int, String, Float, etc) can passed as-is (scalar values). Values for complex Types (objects) can be passed as a HashRef. The keys and values of the hashref will be used to instance the underlying object. | ||
| 100 | For the AWS API documentation, see L<https://docs.aws.amazon.com/goto/WebAPI/cloudformation/UpdateStack> | ||
| 101 | |||
| 102 | =head1 ATTRIBUTES | ||
| 103 | |||
| 104 | |||
| 105 | =head2 Capabilities => ArrayRef[Str|Undef] | ||
| 106 | |||
| 107 | In some cases, you must explicitly acknowledge that your stack template | ||
| 108 | contains certain capabilities in order for AWS CloudFormation to update | ||
| 109 | the stack. | ||
| 110 | |||
| 111 | =over | ||
| 112 | |||
| 113 | =item * | ||
| 114 | |||
| 115 | C<CAPABILITY_IAM> and C<CAPABILITY_NAMED_IAM> | ||
| 116 | |||
| 117 | Some stack templates might include resources that can affect | ||
| 118 | permissions in your AWS account; for example, by creating new AWS | ||
| 119 | Identity and Access Management (IAM) users. For those stacks, you must | ||
| 120 | explicitly acknowledge this by specifying one of these capabilities. | ||
| 121 | |||
| 122 | The following IAM resources require you to specify either the | ||
| 123 | C<CAPABILITY_IAM> or C<CAPABILITY_NAMED_IAM> capability. | ||
| 124 | |||
| 125 | =over | ||
| 126 | |||
| 127 | =item * | ||
| 128 | |||
| 129 | If you have IAM resources, you can specify either capability. | ||
| 130 | |||
| 131 | =item * | ||
| 132 | |||
| 133 | If you have IAM resources with custom names, you I<must> specify | ||
| 134 | C<CAPABILITY_NAMED_IAM>. | ||
| 135 | |||
| 136 | =item * | ||
| 137 | |||
| 138 | If you don't specify either of these capabilities, AWS CloudFormation | ||
| 139 | returns an C<InsufficientCapabilities> error. | ||
| 140 | |||
| 141 | =back | ||
| 142 | |||
| 143 | If your stack template contains these resources, we recommend that you | ||
| 144 | review all permissions associated with them and edit their permissions | ||
| 145 | if necessary. | ||
| 146 | |||
| 147 | =over | ||
| 148 | |||
| 149 | =item * | ||
| 150 | |||
| 151 | AWS::IAM::AccessKey | ||
| 152 | (https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iam-accesskey.html) | ||
| 153 | |||
| 154 | =item * | ||
| 155 | |||
| 156 | AWS::IAM::Group | ||
| 157 | (https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iam-group.html) | ||
| 158 | |||
| 159 | =item * | ||
| 160 | |||
| 161 | AWS::IAM::InstanceProfile | ||
| 162 | (https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-iam-instanceprofile.html) | ||
| 163 | |||
| 164 | =item * | ||
| 165 | |||
| 166 | AWS::IAM::Policy | ||
| 167 | (https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iam-policy.html) | ||
| 168 | |||
| 169 | =item * | ||
| 170 | |||
| 171 | AWS::IAM::Role | ||
| 172 | (https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-iam-role.html) | ||
| 173 | |||
| 174 | =item * | ||
| 175 | |||
| 176 | AWS::IAM::User | ||
| 177 | (https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iam-user.html) | ||
| 178 | |||
| 179 | =item * | ||
| 180 | |||
| 181 | AWS::IAM::UserToGroupAddition | ||
| 182 | (https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iam-addusertogroup.html) | ||
| 183 | |||
| 184 | =back | ||
| 185 | |||
| 186 | For more information, see Acknowledging IAM Resources in AWS | ||
| 187 | CloudFormation Templates | ||
| 188 | (http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-iam-template.html#capabilities). | ||
| 189 | |||
| 190 | =item * | ||
| 191 | |||
| 192 | C<CAPABILITY_AUTO_EXPAND> | ||
| 193 | |||
| 194 | Some template contain macros. Macros perform custom processing on | ||
| 195 | templates; this can include simple actions like find-and-replace | ||
| 196 | operations, all the way to extensive transformations of entire | ||
| 197 | templates. Because of this, users typically create a change set from | ||
| 198 | the processed template, so that they can review the changes resulting | ||
| 199 | from the macros before actually updating the stack. If your stack | ||
| 200 | template contains one or more macros, and you choose to update a stack | ||
| 201 | directly from the processed template, without first reviewing the | ||
| 202 | resulting changes in a change set, you must acknowledge this | ||
| 203 | capability. This includes the AWS::Include | ||
| 204 | (http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/create-reusable-transform-function-snippets-and-add-to-your-template-with-aws-include-transform.html) | ||
| 205 | and AWS::Serverless | ||
| 206 | (http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/transform-aws-serverless.html) | ||
| 207 | transforms, which are macros hosted by AWS CloudFormation. | ||
| 208 | |||
| 209 | If you want to update a stack from a stack template that contains | ||
| 210 | macros I<and> nested stacks, you must update the stack directly from | ||
| 211 | the template using this capability. | ||
| 212 | |||
| 213 | You should only update stacks directly from a stack template that | ||
| 214 | contains macros if you know what processing the macro performs. | ||
| 215 | |||
| 216 | Each macro relies on an underlying Lambda service function for | ||
| 217 | processing stack templates. Be aware that the Lambda function owner can | ||
| 218 | update the function operation without AWS CloudFormation being | ||
| 219 | notified. | ||
| 220 | |||
| 221 | For more information, see Using AWS CloudFormation Macros to Perform | ||
| 222 | Custom Processing on Templates | ||
| 223 | (http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/template-macros.html). | ||
| 224 | |||
| 225 | =back | ||
| 226 | |||
| 227 | |||
| 228 | |||
| 229 | |||
| 230 | =head2 ClientRequestToken => Str | ||
| 231 | |||
| 232 | A unique identifier for this C<UpdateStack> request. Specify this token | ||
| 233 | if you plan to retry requests so that AWS CloudFormation knows that | ||
| 234 | you're not attempting to update a stack with the same name. You might | ||
| 235 | retry C<UpdateStack> requests to ensure that AWS CloudFormation | ||
| 236 | successfully received them. | ||
| 237 | |||
| 238 | All events triggered by a given stack operation are assigned the same | ||
| 239 | client request token, which you can use to track operations. For | ||
| 240 | example, if you execute a C<CreateStack> operation with the token | ||
| 241 | C<token1>, then all the C<StackEvents> generated by that operation will | ||
| 242 | have C<ClientRequestToken> set as C<token1>. | ||
| 243 | |||
| 244 | In the console, stack operations display the client request token on | ||
| 245 | the Events tab. Stack operations that are initiated from the console | ||
| 246 | use the token format I<Console-StackOperation-ID>, which helps you | ||
| 247 | easily identify the stack operation . For example, if you create a | ||
| 248 | stack using the console, each stack event would be assigned the same | ||
| 249 | token in the following format: | ||
| 250 | C<Console-CreateStack-7f59c3cf-00d2-40c7-b2ff-e75db0987002>. | ||
| 251 | |||
| 252 | |||
| 253 | |||
| 254 | =head2 NotificationARNs => ArrayRef[Str|Undef] | ||
| 255 | |||
| 256 | Amazon Simple Notification Service topic Amazon Resource Names (ARNs) | ||
| 257 | that AWS CloudFormation associates with the stack. Specify an empty | ||
| 258 | list to remove all notification topics. | ||
| 259 | |||
| 260 | |||
| 261 | |||
| 262 | =head2 Parameters => ArrayRef[L<Paws::CloudFormation::Parameter>] | ||
| 263 | |||
| 264 | A list of C<Parameter> structures that specify input parameters for the | ||
| 265 | stack. For more information, see the Parameter | ||
| 266 | (https://docs.aws.amazon.com/AWSCloudFormation/latest/APIReference/API_Parameter.html) | ||
| 267 | data type. | ||
| 268 | |||
| 269 | |||
| 270 | |||
| 271 | =head2 ResourceTypes => ArrayRef[Str|Undef] | ||
| 272 | |||
| 273 | The template resource types that you have permissions to work with for | ||
| 274 | this update stack action, such as C<AWS::EC2::Instance>, | ||
| 275 | C<AWS::EC2::*>, or C<Custom::MyCustomInstance>. | ||
| 276 | |||
| 277 | If the list of resource types doesn't include a resource that you're | ||
| 278 | updating, the stack update fails. By default, AWS CloudFormation grants | ||
| 279 | permissions to all resource types. AWS Identity and Access Management | ||
| 280 | (IAM) uses this parameter for AWS CloudFormation-specific condition | ||
| 281 | keys in IAM policies. For more information, see Controlling Access with | ||
| 282 | AWS Identity and Access Management | ||
| 283 | (https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-iam-template.html). | ||
| 284 | |||
| 285 | |||
| 286 | |||
| 287 | =head2 RoleARN => Str | ||
| 288 | |||
| 289 | The Amazon Resource Name (ARN) of an AWS Identity and Access Management | ||
| 290 | (IAM) role that AWS CloudFormation assumes to update the stack. AWS | ||
| 291 | CloudFormation uses the role's credentials to make calls on your | ||
| 292 | behalf. AWS CloudFormation always uses this role for all future | ||
| 293 | operations on the stack. As long as users have permission to operate on | ||
| 294 | the stack, AWS CloudFormation uses this role even if the users don't | ||
| 295 | have permission to pass it. Ensure that the role grants least | ||
| 296 | privilege. | ||
| 297 | |||
| 298 | If you don't specify a value, AWS CloudFormation uses the role that was | ||
| 299 | previously associated with the stack. If no role is available, AWS | ||
| 300 | CloudFormation uses a temporary session that is generated from your | ||
| 301 | user credentials. | ||
| 302 | |||
| 303 | |||
| 304 | |||
| 305 | =head2 RollbackConfiguration => L<Paws::CloudFormation::RollbackConfiguration> | ||
| 306 | |||
| 307 | The rollback triggers for AWS CloudFormation to monitor during stack | ||
| 308 | creation and updating operations, and for the specified monitoring | ||
| 309 | period afterwards. | ||
| 310 | |||
| 311 | |||
| 312 | |||
| 313 | =head2 B<REQUIRED> StackName => Str | ||
| 314 | |||
| 315 | The name or unique stack ID of the stack to update. | ||
| 316 | |||
| 317 | |||
| 318 | |||
| 319 | =head2 StackPolicyBody => Str | ||
| 320 | |||
| 321 | Structure containing a new stack policy body. You can specify either | ||
| 322 | the C<StackPolicyBody> or the C<StackPolicyURL> parameter, but not | ||
| 323 | both. | ||
| 324 | |||
| 325 | You might update the stack policy, for example, in order to protect a | ||
| 326 | new resource that you created during a stack update. If you do not | ||
| 327 | specify a stack policy, the current policy that is associated with the | ||
| 328 | stack is unchanged. | ||
| 329 | |||
| 330 | |||
| 331 | |||
| 332 | =head2 StackPolicyDuringUpdateBody => Str | ||
| 333 | |||
| 334 | Structure containing the temporary overriding stack policy body. You | ||
| 335 | can specify either the C<StackPolicyDuringUpdateBody> or the | ||
| 336 | C<StackPolicyDuringUpdateURL> parameter, but not both. | ||
| 337 | |||
| 338 | If you want to update protected resources, specify a temporary | ||
| 339 | overriding stack policy during this update. If you do not specify a | ||
| 340 | stack policy, the current policy that is associated with the stack will | ||
| 341 | be used. | ||
| 342 | |||
| 343 | |||
| 344 | |||
| 345 | =head2 StackPolicyDuringUpdateURL => Str | ||
| 346 | |||
| 347 | Location of a file containing the temporary overriding stack policy. | ||
| 348 | The URL must point to a policy (max size: 16KB) located in an S3 bucket | ||
| 349 | in the same Region as the stack. You can specify either the | ||
| 350 | C<StackPolicyDuringUpdateBody> or the C<StackPolicyDuringUpdateURL> | ||
| 351 | parameter, but not both. | ||
| 352 | |||
| 353 | If you want to update protected resources, specify a temporary | ||
| 354 | overriding stack policy during this update. If you do not specify a | ||
| 355 | stack policy, the current policy that is associated with the stack will | ||
| 356 | be used. | ||
| 357 | |||
| 358 | |||
| 359 | |||
| 360 | =head2 StackPolicyURL => Str | ||
| 361 | |||
| 362 | Location of a file containing the updated stack policy. The URL must | ||
| 363 | point to a policy (max size: 16KB) located in an S3 bucket in the same | ||
| 364 | Region as the stack. You can specify either the C<StackPolicyBody> or | ||
| 365 | the C<StackPolicyURL> parameter, but not both. | ||
| 366 | |||
| 367 | You might update the stack policy, for example, in order to protect a | ||
| 368 | new resource that you created during a stack update. If you do not | ||
| 369 | specify a stack policy, the current policy that is associated with the | ||
| 370 | stack is unchanged. | ||
| 371 | |||
| 372 | |||
| 373 | |||
| 374 | =head2 Tags => ArrayRef[L<Paws::CloudFormation::Tag>] | ||
| 375 | |||
| 376 | Key-value pairs to associate with this stack. AWS CloudFormation also | ||
| 377 | propagates these tags to supported resources in the stack. You can | ||
| 378 | specify a maximum number of 50 tags. | ||
| 379 | |||
| 380 | If you don't specify this parameter, AWS CloudFormation doesn't modify | ||
| 381 | the stack's tags. If you specify an empty value, AWS CloudFormation | ||
| 382 | removes all associated tags. | ||
| 383 | |||
| 384 | |||
| 385 | |||
| 386 | =head2 TemplateBody => Str | ||
| 387 | |||
| 388 | Structure containing the template body with a minimum length of 1 byte | ||
| 389 | and a maximum length of 51,200 bytes. (For more information, go to | ||
| 390 | Template Anatomy | ||
| 391 | (https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/template-anatomy.html) | ||
| 392 | in the AWS CloudFormation User Guide.) | ||
| 393 | |||
| 394 | Conditional: You must specify only one of the following parameters: | ||
| 395 | C<TemplateBody>, C<TemplateURL>, or set the C<UsePreviousTemplate> to | ||
| 396 | C<true>. | ||
| 397 | |||
| 398 | |||
| 399 | |||
| 400 | =head2 TemplateURL => Str | ||
| 401 | |||
| 402 | Location of file containing the template body. The URL must point to a | ||
| 403 | template that is located in an Amazon S3 bucket or a Systems Manager | ||
| 404 | document. For more information, go to Template Anatomy | ||
| 405 | (https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/template-anatomy.html) | ||
| 406 | in the AWS CloudFormation User Guide. | ||
| 407 | |||
| 408 | Conditional: You must specify only one of the following parameters: | ||
| 409 | C<TemplateBody>, C<TemplateURL>, or set the C<UsePreviousTemplate> to | ||
| 410 | C<true>. | ||
| 411 | |||
| 412 | |||
| 413 | |||
| 414 | =head2 UsePreviousTemplate => Bool | ||
| 415 | |||
| 416 | Reuse the existing template that is associated with the stack that you | ||
| 417 | are updating. | ||
| 418 | |||
| 419 | Conditional: You must specify only one of the following parameters: | ||
| 420 | C<TemplateBody>, C<TemplateURL>, or set the C<UsePreviousTemplate> to | ||
| 421 | C<true>. | ||
| 422 | |||
| 423 | |||
| 424 | |||
| 425 | |||
| 426 | =head1 SEE ALSO | ||
| 427 | |||
| 428 | This class forms part of L<Paws>, documenting arguments for method UpdateStack in L<Paws::CloudFormation> | ||
| 429 | |||
| 430 | =head1 BUGS and CONTRIBUTIONS | ||
| 431 | |||
| 432 | The source code is located here: L<https://github.com/pplu/aws-sdk-perl> | ||
| 433 | |||
| 434 | Please report bugs to: L<https://github.com/pplu/aws-sdk-perl/issues> | ||
| 435 | |||
| 436 | =cut | ||
| 437 |