AWS DevOps Engineer Professional Practice Test

Disable ads (and more) with a membership for a one time $2.99 payment

Prepare for the AWS DevOps Engineer Professional Test. Enhance your skills with flashcards and multiple-choice questions, each offering hints and explanations. Become exam-ready!

Practice this question and more.


How can you pause continuation of a CloudFormation stack creation until after some software is installed on EC2 instances?

  1. Use a RollbackPolicy

  2. Use UserData scripts

  3. Use a CreationPolicy and helper scripts

  4. Use an IAM Policy

The correct answer is: Use a CreationPolicy and helper scripts

To pause the continuation of a CloudFormation stack creation until certain conditions are met, such as software installation on EC2 instances, utilizing a CreationPolicy along with helper scripts is the most effective solution. The CreationPolicy is specifically designed to wait for instances to reach a stable state before considering the resource as created and allowing the stack operation to proceed. By applying a CreationPolicy, you can specify wait conditions that block stack creation until the specified condition is satisfied. The helper scripts can be used to report the status back to CloudFormation once the software installation process on the EC2 instances is complete. This ensures that the stack does not continue until the right conditions are met, improving the reliability of your deployments. The other options do not serve this purpose effectively. While RollbackPolicy and IAM Policies are critical for managing stack operations and permissions respectively, they do not inherently control the timing of resource readiness and continuation of stack operations. UserData scripts, although useful for bootstrapping EC2 instances and executing commands at launch, do not provide a mechanism to pause stack creation while waiting for those commands to complete.