AnsiblePilot — Master Ansible Automation

AnsiblePilot is the leading resource for learning Ansible automation, DevOps, and infrastructure as code. Browse over 1,400 tutorials covering Ansible modules, playbooks, roles, collections, and real-world examples. Whether you are a beginner or an experienced engineer, our step-by-step guides help you automate Linux, Windows, cloud, containers, and network infrastructure.

Popular Topics

About Luca Berton

Luca Berton is an Ansible automation expert, author of 8 Ansible books published by Apress and Leanpub including "Ansible for VMware by Examples" and "Ansible for Kubernetes by Example", and creator of the Ansible Pilot YouTube channel. He shares practical automation knowledge through tutorials, books, and video courses to help IT professionals and DevOps engineers master infrastructure automation.

Install Ansible Automation Controller on a Single Host with Internal DB

By Luca Berton · Published 2024-01-01 · Category: installation

Learn how to install Red Hat Ansible Automation Platform on a single host with an internal database.

Install Ansible Automation Controller on a Single Host with Internal DB

Standalone automation controller with internal database (single host)

The following inventory file is used to install the Red Hat Ansible Automation Platform with one Ansible Automation Controller. This installation inventory file installs one single automation controller node with an internal database “host1.example.com”.

[automationcontroller]
host1.example.com node_type=hybrid

[all:vars] admin_password='<password>' pg_host='' pg_port='5432' pg_database='awx' pg_username='awx' pg_password='<password>' pg_sslmode='prefer'

registry_url='registry.redhat.io' registry_username='<registry username>' registry_password='<registry password>'

With the following parameters: • [automationcontroller] The hostname and the node type. In this case host1.example.com and hybrid type. The hybrid type act as a controller and execution node • admin_password: the password of the “admin” user in the Web user interface • pg_password: the password of the PostgreSQL database • registry_username: the Red Hat Consumer username • registry_password: the Red Hat Consumer password

See also: Master Ansible Automation Platform: Simplify IT Management

Conclusion

Standalone Automation Controllers with internal databases are useful in developer scenarios or a small automation workflow.

Related Articles

Ansible inventory file structurethe Ansible AWX overview

See also: Ansible Community General Collection 7.0.0 Released: Key Changes and Enhancements

See also

How to install Ansible in Rocky Linux 10Ansible Install Docker: Automate Docker Installation on Linux (Complete Guide)

Prerequisites

Before installing Ansible Automation Platform, ensure: • Operating System: Red Hat Enterprise Linux 8.6+ or 9.x (x86_64) • Minimum Hardware: 4 CPUs, 16 GB RAM, 40 GB disk • Network: Access to registry.redhat.io and Red Hat CDN • Subscription: Active Red Hat Ansible Automation Platform subscription • DNS: Hostname resolves correctly (host1.example.com)

# Verify RHEL version
cat /etc/redhat-release

# Register system with Red Hat sudo subscription-manager register sudo subscription-manager attach --auto

# Enable required repositories sudo subscription-manager repos \ --enable ansible-automation-platform-2.3-for-rhel-9-x86_64-rpms

See also: Ansible Core 2.14.2 & Community 7.2.0: Latest Updates

Download the Installer

# Download the setup bundle from access.redhat.com
# Navigate to: Downloads → Ansible Automation Platform → Setup Bundle

# Extract the bundle tar xvf ansible-automation-platform-setup-bundle-2.3-*.tar.gz cd ansible-automation-platform-setup-bundle-2.3-*/

Installation Steps

Step 1: Edit the Inventory File

# Edit the inventory file
vi inventory

Replace the placeholder values with your actual passwords and registry credentials.

Step 2: Run the Installer

# Run the setup script
sudo ./setup.sh

The installation takes 15-30 minutes depending on hardware and network speed.

Step 3: Verify Installation

# Check automation controller service
sudo systemctl status automation-controller

# Verify web interface is accessible curl -k https://host1.example.com/api/v2/ping/

Step 4: Access the Web Interface

Open your browser and navigate to https://host1.example.com. Log in with: • Username: adminPassword: The admin_password from your inventory file

Post-Installation Configuration

# Example: Create a project via the API
- name: Configure Automation Controller
  hosts: localhost
  connection: local
  vars:
    controller_host: https://host1.example.com
    controller_username: admin
    controller_password: "{{ vault_controller_password }}"

tasks: - name: Create organization awx.awx.organization: name: "My Organization" description: "Main organization" controller_host: "{{ controller_host }}" controller_username: "{{ controller_username }}" controller_password: "{{ controller_password }}" validate_certs: false

- name: Create project awx.awx.project: name: "Ansible Playbooks" organization: "My Organization" scm_type: git scm_url: "https://github.com/example/ansible-playbooks.git" controller_host: "{{ controller_host }}" controller_username: "{{ controller_username }}" controller_password: "{{ controller_password }}" validate_certs: false

Troubleshooting

Installer Fails with Registry Authentication Error

# Verify registry credentials
podman login registry.redhat.io

# If using a service account, ensure it has the correct permissions

Cannot Access Web Interface

# Check firewall
sudo firewall-cmd --add-service=https --permanent
sudo firewall-cmd --reload

# Check service status sudo automation-controller-service status

FAQ

Is single-node suitable for production?

Single-node installations are designed for development, testing, and small teams (<20 users). For production with high availability, use a clustered deployment with external databases.

Can I upgrade from single-node to clustered later?

Yes. You can migrate from a standalone installation to a clustered deployment by updating the inventory file and re-running the installer with additional controller and database nodes.

What is the difference between hybrid and control node types?

A hybrid node acts as both a controller and execution node — it manages jobs and runs them. A control node only manages jobs and delegates execution to separate execution nodes.

How do I back up the internal database?

# Use the setup script's backup feature
sudo ./setup.sh -b

# Backup is stored in /var/lib/awx/backup/

Category: installation

Watch the video: Install Ansible Automation Controller on a Single Host with Internal DB — Video Tutorial

Browse all Ansible tutorials · AnsiblePilot Home