How to do it...

Follow these steps to launch a stack in multiple regions:

  1. Log in to the AWS console and select the N. Virginia (us-east-1) region.
  2. Take note of your account ID in the account dropdown in the menu bar.
  3. If you haven't completed the previous recipe, do so now, and retain the YAML file on your filesystem. We will use that same template in the following step.
  4. Go to the CloudFormation console, and click StackSets, then Create StackSet.
  5. Upload the template file from the previous recipe.
  6. Give the stack a descriptive name, and choose an operating system:

StackSet details
  1. Click Next, and then select the role that is to be used for the administration of the StackSet:

StackSet options
  1. Click Next. On the following screen, you will configure the deployment options for the StackSet.
  2. Select Deploy stacks in accounts, and paste in your account number.
  1. Under Specify regions, select US East (N. Virginia) and US West (N. California):

StackSet deployment options
  1. Click Next, then Submit. Wait for the StackSet creation to complete.
  2. Go to the Stack instances tab in order to see the instances that were created:

Stack instances
  1. Go to the EC2 console in each region in order to confirm that the EC2 instances were created.
  2. In order to clean up the resources that were created in this recipe, go back to the CloudFormation console, and select the StackSet.
  3. Select Delete stacks from StackSet from the Actions drop-down menu.
  4. Enter the same configuration information as you did in steps 9-10, in order to specify the account and regions from which to delete stacks.
  5. Click Next, then Submit. Wait until the delete operation finishes.
  6. Now that the stacks are deleted, select Delete StackSet from the Actions drop-down menu.
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset