How it works...

CloudFormation does not maintain a two-way connection with underlying resources. When it comes down to it, CloudFormation only concerns itself with the template as it is written. If you make a change to a resource outside of CloudFormation, your next stack update could go badly, since CloudFormation might attempt to re-create a resource that is already there.

The drift detection feature was added in order to make it easier to spot the differences between your template and the actual resources. At this time, there is strictly a visual tool to help you to identify the resources that need to be manually altered back, in order to match the template. Once there is no drift, then you can safely apply the changes in the template in order to reproduce what someone did manually.

But wait. I'm sure that you are wondering, What if I detect drift in a resource that is not easy to roll back, such as a database? Well, that's why you should try really, really hard never to introduce drift in the first place. CloudFormation may someday support the notion of resource adoption, but for the time being, your only recourse is to roll back, and get things to the way that CloudFormation expects them to be.

..................Content has been hidden....................

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