- Mastering OpenStack(Second Edition)
- Omar Khedher Chandan Dutta Chowdhury
- 278字
- 2021-07-02 23:52:46
Introducing Ansible
We have chosen Ansible to automate our cloud infrastructure. Ansible is an infrastructure automation engine. It is simple to get started with, and yet is flexible enough to handle complex, interdependent systems.
The architecture of Ansible consists of the deployment system where Ansible itself is installed and the target systems that are managed by Ansible. It uses an agentless architecture to push changes to the target systems. This is due to the use of SSH protocol as its transport mechanism to push changes to the target systems. This also means that there is no extra software installation required on the target system. The agentless architecture makes setting up Ansible very simple.
Ansible works by copying modules over SSH to the target systems. It then executes them to change the state of the target systems. Once executed, the Ansible modules are cleaned up, leaving no trail on the target system.
Although the default mechanism for making changes to the client system is an SSH-based push model, if you feel the push-based model for delivering changes is not scalable enough for your infrastructure, Ansible also supports an agent-based pull-model.
Ansible is developed in Python and comes with a huge collection of core automation modules.
The configuration files for Ansible are called playbooks and they are written in YAML, which is just a markup language. YAML is easier to understand; it's custom-made for writing configuration files. This makes learning Ansible automation much easier.
The Ansible Galaxy is a collection of reusable Ansible modules that can be used for your project.
To read more about Ansible, please refer to the official website that contains great wiki documentation: http://docs.ansible.com/ansible/intro.html