cloudformation vs terraform_vs_ansible
TRANSCRIPT
![Page 1: Cloudformation vs terraform_vs_ansible](https://reader031.vdocument.in/reader031/viewer/2022021814/58ef3c0e1a28ab56528b459d/html5/thumbnails/1.jpg)
#8 Forming clouds: CloudFormation vs
Ansible vs TerraForm
![Page 2: Cloudformation vs terraform_vs_ansible](https://reader031.vdocument.in/reader031/viewer/2022021814/58ef3c0e1a28ab56528b459d/html5/thumbnails/2.jpg)
![Page 3: Cloudformation vs terraform_vs_ansible](https://reader031.vdocument.in/reader031/viewer/2022021814/58ef3c0e1a28ab56528b459d/html5/thumbnails/3.jpg)
Geert Theys
Sales guy @skyscrapersStill likes to get his hands dirty.
github.com/gtheys twitter.com/toadi geerttheys.com
![Page 4: Cloudformation vs terraform_vs_ansible](https://reader031.vdocument.in/reader031/viewer/2022021814/58ef3c0e1a28ab56528b459d/html5/thumbnails/4.jpg)
Mattias Gees
Cloud Engineer @skyscrapers
Likes to experiment!
github.com/mattiasgees twitter.com/mattiasgees blog.mattiasgees.be
![Page 5: Cloudformation vs terraform_vs_ansible](https://reader031.vdocument.in/reader031/viewer/2022021814/58ef3c0e1a28ab56528b459d/html5/thumbnails/5.jpg)
CloudFormation<> Terraform
<> Ansiblefor AWS provisioning
![Page 6: Cloudformation vs terraform_vs_ansible](https://reader031.vdocument.in/reader031/viewer/2022021814/58ef3c0e1a28ab56528b459d/html5/thumbnails/6.jpg)
All different toolsand there are many others!
![Page 7: Cloudformation vs terraform_vs_ansible](https://reader031.vdocument.in/reader031/viewer/2022021814/58ef3c0e1a28ab56528b459d/html5/thumbnails/7.jpg)
All have their advantages
![Page 8: Cloudformation vs terraform_vs_ansible](https://reader031.vdocument.in/reader031/viewer/2022021814/58ef3c0e1a28ab56528b459d/html5/thumbnails/8.jpg)
And disadvantages
![Page 9: Cloudformation vs terraform_vs_ansible](https://reader031.vdocument.in/reader031/viewer/2022021814/58ef3c0e1a28ab56528b459d/html5/thumbnails/9.jpg)
Before we start!
![Page 10: Cloudformation vs terraform_vs_ansible](https://reader031.vdocument.in/reader031/viewer/2022021814/58ef3c0e1a28ab56528b459d/html5/thumbnails/10.jpg)
Lets compare
![Page 11: Cloudformation vs terraform_vs_ansible](https://reader031.vdocument.in/reader031/viewer/2022021814/58ef3c0e1a28ab56528b459d/html5/thumbnails/11.jpg)
Simple syntax?
![Page 12: Cloudformation vs terraform_vs_ansible](https://reader031.vdocument.in/reader031/viewer/2022021814/58ef3c0e1a28ab56528b459d/html5/thumbnails/12.jpg)
CloudFormation:
![Page 13: Cloudformation vs terraform_vs_ansible](https://reader031.vdocument.in/reader031/viewer/2022021814/58ef3c0e1a28ab56528b459d/html5/thumbnails/13.jpg)
Terraform:
![Page 14: Cloudformation vs terraform_vs_ansible](https://reader031.vdocument.in/reader031/viewer/2022021814/58ef3c0e1a28ab56528b459d/html5/thumbnails/14.jpg)
Ansible:
![Page 15: Cloudformation vs terraform_vs_ansible](https://reader031.vdocument.in/reader031/viewer/2022021814/58ef3c0e1a28ab56528b459d/html5/thumbnails/15.jpg)
Which one was the easiest to read?
![Page 16: Cloudformation vs terraform_vs_ansible](https://reader031.vdocument.in/reader031/viewer/2022021814/58ef3c0e1a28ab56528b459d/html5/thumbnails/16.jpg)
Easy to install?Package managers:
• brew install
• apt-get install
• yum install
Warning: None are up to date!
Latest versions pip and/or sources
![Page 17: Cloudformation vs terraform_vs_ansible](https://reader031.vdocument.in/reader031/viewer/2022021814/58ef3c0e1a28ab56528b459d/html5/thumbnails/17.jpg)
Safe to use?Terraform and Ansible have a plan or --check mode
![Page 18: Cloudformation vs terraform_vs_ansible](https://reader031.vdocument.in/reader031/viewer/2022021814/58ef3c0e1a28ab56528b459d/html5/thumbnails/18.jpg)
Productive?
![Page 19: Cloudformation vs terraform_vs_ansible](https://reader031.vdocument.in/reader031/viewer/2022021814/58ef3c0e1a28ab56528b459d/html5/thumbnails/19.jpg)
It's running ;)• CloudFormation:
• Parallelizes as much as possible
• Terraform:
• Use dependency graph and parallelizes as much as possible
• Partial refresh before changes
• Ansible:
![Page 20: Cloudformation vs terraform_vs_ansible](https://reader031.vdocument.in/reader031/viewer/2022021814/58ef3c0e1a28ab56528b459d/html5/thumbnails/20.jpg)
How do they keep state?• Cloudformation on AWS
• Terraform creates a state file
• Ansible ad hoc state
![Page 21: Cloudformation vs terraform_vs_ansible](https://reader031.vdocument.in/reader031/viewer/2022021814/58ef3c0e1a28ab56528b459d/html5/thumbnails/21.jpg)
Do I feel safe• CloudFormation:
• Start to pray when you run it
• Roll back on fail
• Terraform:
• Partial State gets stored on error (eg. sg gets created not the rules, next run will fix this)
• Create before destroy
![Page 22: Cloudformation vs terraform_vs_ansible](https://reader031.vdocument.in/reader031/viewer/2022021814/58ef3c0e1a28ab56528b459d/html5/thumbnails/22.jpg)
Issues?• CloudFormation:
• JSON
• No partial run possible
• Terraform:
• No full coverage of AWS
• Ansible:
• Not every aws module has --dry-run check mode!
![Page 23: Cloudformation vs terraform_vs_ansible](https://reader031.vdocument.in/reader031/viewer/2022021814/58ef3c0e1a28ab56528b459d/html5/thumbnails/23.jpg)
Legacy projects?• Cloudformation: Cloudformer
• Terraform: Terraforming
• Ansible: Just do it
![Page 24: Cloudformation vs terraform_vs_ansible](https://reader031.vdocument.in/reader031/viewer/2022021814/58ef3c0e1a28ab56528b459d/html5/thumbnails/24.jpg)
![Page 25: Cloudformation vs terraform_vs_ansible](https://reader031.vdocument.in/reader031/viewer/2022021814/58ef3c0e1a28ab56528b459d/html5/thumbnails/25.jpg)
Do you look cool when using it?
![Page 26: Cloudformation vs terraform_vs_ansible](https://reader031.vdocument.in/reader031/viewer/2022021814/58ef3c0e1a28ab56528b459d/html5/thumbnails/26.jpg)
Do I want to use it?• Terraform: Destroy ordering, clean and readable, focus on 1
thing
• Ansible: It's simple
• Cloudformation: Who likes JSON?
![Page 27: Cloudformation vs terraform_vs_ansible](https://reader031.vdocument.in/reader031/viewer/2022021814/58ef3c0e1a28ab56528b459d/html5/thumbnails/27.jpg)
Do we recommend 1?
![Page 28: Cloudformation vs terraform_vs_ansible](https://reader031.vdocument.in/reader031/viewer/2022021814/58ef3c0e1a28ab56528b459d/html5/thumbnails/28.jpg)
Questions?Presentation + demo on github.com/skyscrapers/demo-aws-meetup
![Page 29: Cloudformation vs terraform_vs_ansible](https://reader031.vdocument.in/reader031/viewer/2022021814/58ef3c0e1a28ab56528b459d/html5/thumbnails/29.jpg)