AWS Cloudformation in 5 mins [Quick Start]

AWS Cloudformation in 5 mins [Quick Start]

Joey Göksu

I’ve been using Amazon Web Services (AWS) last 3 years from now on but I’ve not used Cloudformation directly. I prefer to use the AWS CDK, Pulumi or Terraform. I think these are making things definetly easier. I’ll write a wider blog post about them in the near future.

Let’s start with the definitions.

What’s IaC? Infrastructure as Code?

“Infrastructure as Code (IaC) is the management of infrastructure (networks, virtual machines, load balancers, and connection topology) in a descriptive model, using the same versioning as DevOps team uses for source code.” -Microsoft

What’s AWS Cloudformation?

“AWS CloudFormation is a service that gives developers and businesses an easy way to create a collection of related AWS and third-party resources, and provision and manage them in an orderly and predictable fashion.” -Microsoft

From my mind map

1 mindmap

As you can see, AWS CloudFormation is a brach under AWS category. Even the other IaC tools are using CloudFormation under the hood. When you execute AWS CDK code, it generates CloudFormation in the background.

Hands-on LAB

  1. Open the AWS Console and go to the CloudFormation page.
  2. Create a new stack.
2 create stack
  1. Pick template is ready and upload the following json file.
// my-stack-name.json
  "Resources": {
    "catpics": {
      "Type": "AWS::S3::Bucket"
3 create stack json
  1. Name your stack.
4 create stack name
  1. Add a tag if you want and click on the create button.
5 create stack tag
  1. Wait for the stack to be created. You can see the stack in the AWS Console.
6 create stack wait
  1. Go to s3 bucket and check the list of buckets.
7 create stack bucket

Tadaaa! You’ve created a new stack successfully. You can update/delete it later. It was a super fast hands-on lab.

See you in the next hands-on lab.

Crafted with ❤️ in multiple locations [🇬🇧 🇺🇸 🇹🇷 🇷🇺]. · © 2022