Slide 1

Slide 1 text

AWS CloudFormation Speed up cloud provisioning with infrastructure as code (IaC) Will Chalmers (he/him) Solutions Architect

Slide 2

Slide 2 text

• What is AWS CloudFormation • Template Structure • Intrinsic Functions • Pseudo Parameters • Code Standards & Template Library • Demo Agenda

Slide 3

Slide 3 text

What is AWS CloudFormation

Slide 4

Slide 4 text

YAML JSON They do the same thing

Slide 5

Slide 5 text

Parameters

Slide 6

Slide 6 text

Metadata

Slide 7

Slide 7 text

Mappings Key/Value pairs which can be used for lookups

Slide 8

Slide 8 text

Conditions

Slide 9

Slide 9 text

Resources

Slide 10

Slide 10 text

Outputs

Slide 11

Slide 11 text

Stack Deployment

Slide 12

Slide 12 text

Logical v Physical Resources Application Load Balancer

Slide 13

Slide 13 text

Intrinsic Functions Function Name Description Ref / !Ref Returns the value of the specified parameter or resource Fn::Sub / !Sub Substitutes variables inside a string. Fn::GetAtt / !GetAtt Returns the value of an attribute from a resource in the template. Fn::Join / !Join Joins a set of values into one value Plus lots more, Fn::Length, Fn::Split, Fn::ImportValue

Slide 14

Slide 14 text

Other Features Drift Detection Deletion Policy Stack Roles Change Sets A feature that analyses CloudFormation stacks for any changes to resources made manually. Changes to CloudFormed resources out with CloudFormation can be problematic A setting for some resources stating how they will be deleted: • Delete • Retain • Snapshot A role that is used to deploy a stack. Meaning it can have more permissions than the user deploying it. A dry run template update to view resource changes before they are executed. It shows: • Replacements • Deletions • Creations • Changes

Slide 15

Slide 15 text

Code Standards & Template Library Code standards document - How CloudFormation should be written, tested and deployed Setting up your IDE document – Recommended optimal IDE configuration for CloudFormation/aws development Template Library – GitHub repo with code snippets & full templates to reference.

Slide 16

Slide 16 text

Thank You! Q&A + Demo Time