When creating an AWS EC2 instance, there is a User Data section where you can include scripts that will be run immediately upon instance creation. I was attempting to use AWS CloudFormation to define the infrastructure of my current project and ran into the issue of how to include the User Data section in the CloudFormation JSON definition.
A CloudFormation script to get a docker instance of pi-hole running in your AWS account
What is pi-hole?
Infrastructure as code is amazing. The fact that we can build entire environments using CODE is nothing short of miraculous. But tell me if this has ever happened to you:
This is the first in a series of posts team Observian will be publishing on AWS Cloudformation. As the name suggests, this is a basic introductory article on Cloudformation. A paint brush is what I would compare Cloudformation to, AWS platform is my canvas and offerings like EC2, S3, VPC, ELB etc. are my colors to paint those elegant paintings called stacks of resources. Now, what are the building blocks of Cloudformation? Well, there are 3, namely, template, stack & change set. Template is considered the user's playground and the heart of Cloudformation.