XenonStack

DevOps

XenonStack Blog

What Is Ansible? Configuration Management Guide

and | Published | Updated

What Is Ansible? Configuration Management Guide
13:15

Key takeaway

  • Ansible explained for enterprise teams: how playbooks and inventory work, what ansible-core 2.21 and Event-Driven Ansible change, and how to govern it.
. #}

What is Ansible and where does it fit in configuration management?

Ansible is open-source automation for maintaining system configuration, deploying software and running rolling updates. You declare the desired state of a system in a human-readable playbook and Ansible keeps the system in that state. This guide takes the configuration management angle. For the wider picture of provisioning tools, read our guide to infrastructure as code.

For an enterprise leader, the question is not whether Ansible can install a package. It is whether configuration, patching and compliance settings can be written once, reviewed like code and applied the same way to every host. Below we cover how Ansible works, what changed in 2026, how it relates to Red Hat Ansible Automation Platform, and how to adopt it with governance. Compare the wider toolchain in our DevOps tools guide and the infrastructure as code tools guide.

How does Ansible work?

Per the Ansible basic concepts page, you run Ansible from a control node against managed nodes, which are listed in an inventory. Ansible copies modules to the managed nodes to carry out each task, and normally nothing is installed on them. It is decentralised and uses SSH with existing operating system credentials (Ansible introduction).

Two-column diagram mapping needs (repeatable setup, shared governance, event response, safe change) to Ansible components (playbooks, Automation Platform, Event-Driven Ansible, staging and vault).
TermWhat the documentation says
Control nodeThe machine where you run tools such as ansible-playbook. A laptop, shared desktop or server can serve.
Managed nodesThe target devices, also called hosts. Ansible is normally not installed on them.
InventoryA list of managed nodes, with details such as IP addresses and group membership for selecting nodes and setting variables in bulk.
PlaybookA YAML file containing plays, the basic unit of Ansible execution.
TaskThe definition of an action to apply to a managed host.
ModuleCode that Ansible copies to managed nodes and runs to carry out a task. Modules are grouped into collections.
CollectionA distribution format that can bundle playbooks, roles, modules and plugins, installable through Ansible Galaxy.

What does a playbook look like?

The example below is illustrative. It targets a group of web servers, installs a package, deploys a templated file and makes sure a service is running. It states the desired state explicitly and uses fully qualified collection names, both practices from the Ansible tips page.

---
- name: Configure web servers
  hosts: webservers
  tasks:
    - name: Install the web server package
      ansible.builtin.apt:
        name: apache2
        state: present

    - name: Deploy the site configuration
      ansible.builtin.template:
        src: site.conf.j2
        dest: /etc/apache2/sites-available/site.conf

    - name: Ensure the service is running
      ansible.builtin.service:
        name: apache2
        state: started

Because playbooks are idempotent, running one again on a host that is already in the described state changes nothing. That is what makes repeated runs safe and drift visible. A quick connectivity check across the whole inventory is ansible all -m ping.

Video: an overview of Ansible from XenonStack.

What has changed in Ansible in 2026?

Ansible ships a major ansible-core release roughly every six months, in May and November, with patch releases every four weeks. The latest release and the two before it are maintained. The table is from the release and maintenance page, read on 12 November 2026.

ansible-coreGeneral availabilityCritical fixes untilSecurity fixes untilEnd of lifeControl node Python
2.21May 2026Nov 2026May 2027Nov 20273.12 to 3.14
2.2003 Nov 202518 May 202602 Nov 2026May 20273.12 to 3.14
2.1921 Jul 202503 Nov 202518 May 2026Nov 20263.11 to 3.13

Versions 2.17 and earlier are listed as end of life. Control nodes support the three most recent Python versions, and managed nodes support the six most recent, so an old Python on a managed host can block an upgrade. From 2.21 each release also supports the latest PowerShell 7.x LTS alongside Windows PowerShell 5.1. Pin your ansible-core version, test upgrades in staging and plan around the end-of-life column.

What do Red Hat Ansible Automation Platform and Event-Driven Ansible add?

Ansible itself is open source. Red Hat sells Red Hat Ansible Automation Platform, which its page lists as including automation controller, automation execution environments, automation mesh, Ansible Content Collections, automation hub, Event-Driven Ansible, a self-service automation portal and an automation dashboard and analytics. The older name "Ansible Tower" still appears in searches, but we could not confirm the rename on Red Hat pages, so check the current product names with Red Hat before you plan a purchase.

NeedComponentWhen it fitsStatus and cost
Playbooks run by engineersOpen-source ansible-coreSmall and mid-sized estates, one team, no central approval flowOpen source; support follows the release matrix above
Shared execution, scale and governanceAnsible Automation Platform (automation controller, hub, execution environments)Several teams, shared inventories, controlled contentRed Hat subscription
Automated response to eventsEvent-Driven AnsibleAlerts from observability tools should trigger a known fixIncluded in the Platform subscription for versions 2.4 and higher, per Red Hat

Event-Driven Ansible works through rulebooks. An event source reports a condition, the engine matches it to a rule and the action runs, for example an existing playbook, template or module. Red Hat gives the example of an unresponsive network router that triggers a configuration reapply, a reset or a service ticket.

How should enterprises govern Ansible and control the risk?

Configuration management changes production at scale, so the control points matter more than the syntax. The Ansible tips page recommends the following, and each maps to a risk a CISO or platform lead will recognise.

RiskControl from the Ansible documentation
Unreviewed changesKeep playbooks, roles, inventory and variables in version control with meaningful commit messages. This gives the audit trail.
Secrets in plain textEncrypt values with ansible-vault encrypt_string or keep vaulted variables in a separate vault file.
Production exposed to other environmentsUse separate inventory files or directories for production and staging.
Large blast radiusTest in staging first, run --syntax-check and use the serial keyword to update in batches.
Inconsistent environmentsUse execution environments, portable container images, to reduce complexity.

Where AI agents begin to trigger automation like this, the same questions apply to the agent: what it may change, under which policy, with what evidence. AgentGRC keeps autonomous agent actions within policy and records evidence that audit and risk teams can review, and ElixirData Context OS keeps governed context, versioned policy and decision traces in one decision layer above AI agents. Our guide to compliance as code covers the policy side.

What are the best practices for Ansible playbooks and inventory?

  1. Keep it simple. Use advanced features only when necessary.
  2. Name plays, tasks and blocks so the output says what each one does and why.
  3. State the state. Set state: present or state: absent instead of relying on module defaults.
  4. Use fully qualified collection names, for example ansible.builtin.copy.
  5. Group inventory by function, such as webservers and dbservers, and use dynamic inventory with clouds.
  6. Use comments where the code does not explain what, how and why.
  7. Test in staging and update in batches.

These come from the Ansible tips and tricks page. Ansible fits inside a delivery pipeline as well, see our guide to the CI/CD pipeline.

When is Ansible not the right fit, and what are the trade-offs?

  • Windows control nodes. Windows without WSL is not natively supported as a control node.
  • Python and SSH on targets. Managed nodes need Python and an SSH account to a POSIX shell, except network modules, which do not need Python on the device.
  • Version churn. With a release every six months and three maintained versions, upgrade planning is a standing task.
  • Subscription features. Controller, hub and Event-Driven Ansible belong to the paid Platform. Check the licence before relying on them.
  • Provisioning. Ansible configures hosts. For cloud resource creation, compare the tools in our infrastructure as code tools guide.

How should you adopt Ansible, step by step?

  1. Pick one repeatable task, such as a baseline server configuration, and write it as a playbook.
  2. Create a function-grouped inventory with separate production and staging.
  3. Put everything in version control and review changes like code.
  4. Add vault for secrets and run in staging with --syntax-check first.
  5. Roll out in batches with serial, then add roles and collections for reuse.
  6. Decide whether shared governance justifies Ansible Automation Platform, and whether events should trigger runs.

For teams extending this into agent-driven operations, ElixirClaw is an agentic OS platform to build, orchestrate and govern AI agents and automation workflows while keeping humans in control. See also our guide to intelligent automation with agentic AI.

To map one configuration or remediation decision your agents should make, and the context and policy it depends on, book a Context Workshop. See what happens in the workshop.

Frequently asked questions about Ansible

What is Ansible used for?

Ansible is open-source automation. Its documentation lists eliminating repetitive work, maintaining system configuration, deploying software and zero-downtime rolling updates as typical uses.

Is Ansible agentless?

Yes. Ansible does not need to be installed on managed nodes. It reaches them over SSH using existing operating system credentials, and managed nodes need Python (network modules are the exception).

Which ansible-core version is current?

On 12 November 2026 the support matrix lists ansible-core 2.21 as the newest release, generally available in May 2026. Versions 2.20 and 2.19 are also maintained, and 2.19 reaches end of life in November 2026.

What is Event-Driven Ansible?

Event-Driven Ansible is a Red Hat Ansible Automation Platform feature. Rulebooks match incoming events from sources such as observability tools to conditions, then run an action such as an existing playbook, template or module.

Should I use Ansible or Terraform?

Treat them as different jobs rather than rivals. Our infrastructure as code guide covers provisioning tools, while this guide covers configuring the machines once they exist, so many teams use both.

Table of Contents

navdeep-singh-gill

Navdeep Singh Gill

Global CEO and Founder of XenonStack

LinkedIn profile

Navdeep Singh Gill is serving as Chief Executive Officer and Product Architect at XenonStack. He holds expertise in building SaaS Platform for Decentralised Big Data management and Governance, AI Marketplace for Operationalising and Scaling. His incredible experience in AI Technologies and Big Data Engineering thrills him to write about different use cases and its approach to solutions.

Get the latest articles in your inbox

Subscribe Now

Interested in Solving your Challenges with XenonStack Team
Get Started

Get Started with your requirements and primary focus, that will help us to make your solution

Please Select your Industry
Banking
Fintech
Payment Providers
Wealth Management
Discrete Manufacturing
Semiconductor
Machinery Manufacturing / Automation
Appliances / Electrical / Electronics
Elevator Manufacturing
Defense & Space Manufacturing
Computers & Electronics / Industrial Machinery
Motor Vehicle Manufacturing
Food and Beverages
Distillery & Wines
Beverages
Shipping
Logistics
Mobility (EV / Public Transport)
Energy & Utilities
Hospitality
Digital Gaming Platforms
SportsTech with AI
Public Safety - Explosives
Public Safety - Firefighting
Public Safety - Surveillance
Public Safety - Others
Media Platforms
City Operations
Airlines & Aviation
Defense Warfare & Drones
Robotics Engineering
Drones Manufacturing
AI Labs for Colleges
AI MSP / Quantum / AGI Institutes
Retail Apparel and Fashion

Proceed Next