DEV Community

Cover image for Infrastructure as Code - Red Hat Ansible
Adithya Krishna
Adithya Krishna

Posted on

Infrastructure as Code - Red Hat Ansible

What is Red Hat Ansible?

Ansible is a tool for automating the provisioning and configuration of infrastructure, including both physical servers and virtual machines. It uses a simple, declarative language that is easy to learn and can be used to manage complex deployments. It is an open source project, Ansible GitHub with a large community of users and contributors. It integrates with other tools and technologies, making it a versatile tool for DevOps engineers.

For example, Ansible can be used to automate many common tasks, such as software deployments, infrastructure deployments, configuration management, and more.

Ansible Versions

Why is it interesting/exciting?

Infrastructure as code is an exciting way to manage your infrastructure. With it, you can easily automate and improve the management of your infrastructure using code.

Red Hat Ansible is a powerful tool that makes it easy to automate your infrastructure. With it, you can quickly and easily manage your entire infrastructure from a single place.
Using Ansible, you can also easily manage changes in your infrastructure - adding or removing machines or services without any hassle.

It uses OpenSSH for transport (with other transports and pull modes as alternatives), and uses a human-readable language that is designed for getting started quickly without a lot of training

Lastly, Red Hat Ansible is scalable so you can easily add more machines or services as needed.

Ansible Architecture

Both editions of Ansible, Community and Ansible Automation Platform have two concepts and they are,

  1. Control node - It is where Ansible is executed from, for example where a user runs the ansible-playbook command

  2. Managed node - They are the devices being automated, for example a Microsoft Windows server

For automating Linux and Windows, Ansible works by connecting to managed nodes and pushing out small programs, called "Ansible modules," to them. These programs are written to be resource models of the desired state of the system. Ansible then executes these modules (over SSH by default), and removes them when finished. These modules are designed to be idempotent when possible, so that they only make changes to a system when necessary.

Ansible Architecture

Let's say you want to automate your public clouds or any web service providers, Ansible will also run modules locally and talk directly to their APIs. Here are some guides,

Top comments (0)