Ansible vs CloudFormation vs Terraform

Hi,
I am just getting started with my career in DevOps and have been researching of various technologies to automate infrastructure creation and deployment.
Since I have been working on AWS a lot , my question is more focused on the same cloud provider.

I have been reading lots of blogs and articles where people are experimenting with different tools for infrastructure as a code in AWS. I have seen lots of application where people are using Ansible and CloudFormation, Terraform and Ansible or just Ansible for coding, deployment and automating the infrastructure.

I know Ansible has lots of built-in modules which is self-sufficient to create and orchestrate an infrastructure. I would like to know in general what makes you choose one or the other three choices above.

Like when would you choose to go with an Terraform and Ansible pair instead of Just Ansible.

Thank You :slight_smile:

Hi Rahul,

I cannot speak for Terraform, however a lot of people are using Ansible with the CloudFormation module to manage their deployments, which allows you to parameterize things a bit more easily than you can do when just using CloudFormation via the AWS GUI. Many others are also using the individual modules like ec2, ec2_elb and others to have very fine-grained control over their environment.

I would say it depends on what level of control you want to have when creating your environments, so try out each method and see which fits your needs best.

Thanks!