Introduction to CloudFormation

CloudFormation is an AWS service that helps us to define resources in a specification document and deploy them. We create a document in a unified manner and then feed that definition document to the CloudFormation service through the management console, the CLI, SDK, or directly through the CloudFormation API. The CloudFormation service will, in turn, deploy all of the resources that we have specified and configure them accordingly. In case of any failures upon deployment, the CloudFormation service will also automatically be able to roll back the resources it created so that we never have half-functional CloudFormation deployments in our AWS account.

The power that CloudFormation gives us is the ability to create complete environments in a repeatable and automated fashion. By removing manual activities from deployments, we make the application inherently more reliable and allow for advanced deployment scenarios where not only humans but other automation systems and the code itself call up the CloudFormation service, provide a specification document, and create resources that are required. This enables us to treat our infrastructure as code, which means doing the following:

  • We define the infrastructure in a document.
  • We maintain that document in a repository.
  • We version the document whenever changes occur.
  • We deploy the infrastructure with the same tools that we deploy our code with.

Infrastructure as code is a prerequisite to being able to create a fully automated development, testing, and deployment scenario while at the same time empowering our developers, operations engineers, and administrators by relieving them of the mundane, task-based manual deployments that have a lot of unreliability built into them. The goal of infrastructure as code is to let the computers do the mundane, repeatable tasks that computers are good at while humans do the complex tasks such as writing code, designing, optimizing, estimating, and thinking outside of the box.

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

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