Updating our stack

Having generated the new JSON CloudFormation template, we can get into the CloudFormation console and update the stack as follows:

  1. Open the CloudFormation web console in your browser (https://console.aws.amazon.com/cloudformation).
  2. Select the HelloWorld stack that we previously created.
  3. Click on Action then Update Stack.
  4. Chose the helloworld-cf-v2.template file by clicking on the Browse button selecting the file, and then clicking on Next.
  5. This brings us to the next screen that lets us update the details of our stack. In our case, nothing has changed in the parameters, so we can continue by clicking on Next.

 

  1. In the next screen as well, since we simply want to see the effect of our IP change, we can click on Next.
  2. This brings us to the Review page where after a couple of seconds we can see CloudFormation giving a Preview of our change:

As you can see, the only change will be an update on the security group. Click on Update.

  1. This will bring us back to the CloudFormation template, where we will see the change being applied.

In this particular example, AWS is able simply to update the security group to take our change into account.

We can verify the change by extracting the physical ID from either the Review page or back in the console in the Resources tab:

$ aws ec2 describe-security-groups 
--group-names HelloWorld-HelloWolrdWebServerSecurityGroup-1F7V2BLZLWT1
..................Content has been hidden....................

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