Defining a CloudFormation template

The easiest way to get started with CloudFormation is to create a CloudFormation template. This template is defined in either a JSON or YAML format, with the latter being the format I recommend given YAML is much easier for humans to work with than JSON.

The CloudFormation user guide describes the template structure in great detail, however for the purposes of this book, we only need to worry about a basic template structure which is best demonstrated with a real example, which you can save in a file called stack.yml in a convenient location on your computer:

AWSTemplateFormatVersion: "2010-09-09"Description: Cloud9 Management StationParameters: EC2InstanceType:   Type: String Description: EC2 instance type ...

Get Docker on Amazon Web Services now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.