Ansible
Ansible automates the configuration of servers, the deployment of applications and orchestration tasks. It connects over SSH, needs no agent on the managed hosts and describes the desired state in YAML playbooks.
Key concepts #
- Inventory: the hosts Ansible manages. See dynamic inventory.
- Playbook: the ordered tasks to run. See playbook structure.
- Role: a reusable unit of tasks, templates and variables. See roles best practices.
- Idempotence: running a playbook twice leaves the same result.
Learn it #
Read the Ansible tutorials. It pairs well with Terraform, which creates the servers Ansible then configures.
Install it and write a playbook with Install Ansible and Write Your First Playbook.
More tutorials that use Ansible
- How to use Terraform, AWS, and Ansible Together
- Kubernetes Cluster using Vagrant and Ansible with Containerd (in 3 minutes)
- How to Install Ansible
- Ansible Multiple Environment Best Practices
- AWS VPC, Route 53, RDS MariaDB, EC2 using Ansible and Terraform (1/5)
- Regex in Terraform, Ansible and Prometheus: Functions, Filters and Matchers
- Terraform Provisioners and EC2 user_data: When to Use Each (and Alternatives)
- Creating AWS RDS Database with Terraform (4/5)