Skip to main content
Redhat Developers  Logo
  • Products

    Featured

    • Red Hat Enterprise Linux
      Red Hat Enterprise Linux Icon
    • Red Hat OpenShift AI
      Red Hat OpenShift AI
    • Red Hat Enterprise Linux AI
      Linux icon inside of a brain
    • Image mode for Red Hat Enterprise Linux
      RHEL image mode
    • Red Hat OpenShift
      Openshift icon
    • Red Hat Ansible Automation Platform
      Ansible icon
    • Red Hat Developer Hub
      Developer Hub
    • View All Red Hat Products
    • Linux

      • Red Hat Enterprise Linux
      • Image mode for Red Hat Enterprise Linux
      • Red Hat Universal Base Images (UBI)
    • Java runtimes & frameworks

      • JBoss Enterprise Application Platform
      • Red Hat build of OpenJDK
    • Kubernetes

      • Red Hat OpenShift
      • Microsoft Azure Red Hat OpenShift
      • Red Hat OpenShift Virtualization
      • Red Hat OpenShift Lightspeed
    • Integration & App Connectivity

      • Red Hat Build of Apache Camel
      • Red Hat Service Interconnect
      • Red Hat Connectivity Link
    • AI/ML

      • Red Hat OpenShift AI
      • Red Hat Enterprise Linux AI
    • Automation

      • Red Hat Ansible Automation Platform
      • Red Hat Ansible Lightspeed
    • Developer tools

      • Red Hat Trusted Software Supply Chain
      • Podman Desktop
      • Red Hat OpenShift Dev Spaces
    • Developer Sandbox

      Developer Sandbox
      Try Red Hat products and technologies without setup or configuration fees for 30 days with this shared Openshift and Kubernetes cluster.
    • Try at no cost
  • Technologies

    Featured

    • AI/ML
      AI/ML Icon
    • Linux
      Linux Icon
    • Kubernetes
      Cloud icon
    • Automation
      Automation Icon showing arrows moving in a circle around a gear
    • View All Technologies
    • Programming Languages & Frameworks

      • Java
      • Python
      • JavaScript
    • System Design & Architecture

      • Red Hat architecture and design patterns
      • Microservices
      • Event-Driven Architecture
      • Databases
    • Developer Productivity

      • Developer productivity
      • Developer Tools
      • GitOps
    • Secure Development & Architectures

      • Security
      • Secure coding
    • Platform Engineering

      • DevOps
      • DevSecOps
      • Ansible automation for applications and services
    • Automated Data Processing

      • AI/ML
      • Data Science
      • Apache Kafka on Kubernetes
      • View All Technologies
    • Start exploring in the Developer Sandbox for free

      sandbox graphic
      Try Red Hat's products and technologies without setup or configuration.
    • Try at no cost
  • Learn

    Featured

    • Kubernetes & Cloud Native
      Openshift icon
    • Linux
      Rhel icon
    • Automation
      Ansible cloud icon
    • Java
      Java icon
    • AI/ML
      AI/ML Icon
    • View All Learning Resources

    E-Books

    • GitOps Cookbook
    • Podman in Action
    • Kubernetes Operators
    • The Path to GitOps
    • View All E-books

    Cheat Sheets

    • Linux Commands
    • Bash Commands
    • Git
    • systemd Commands
    • View All Cheat Sheets

    Documentation

    • API Catalog
    • Product Documentation
    • Legacy Documentation
    • Red Hat Learning

      Learning image
      Boost your technical skills to expert-level with the help of interactive lessons offered by various Red Hat Learning programs.
    • Explore Red Hat Learning
  • Developer Sandbox

    Developer Sandbox

    • Access Red Hat’s products and technologies without setup or configuration, and start developing quicker than ever before with our new, no-cost sandbox environments.
    • Explore Developer Sandbox

    Featured Developer Sandbox activities

    • Get started with your Developer Sandbox
    • OpenShift virtualization and application modernization using the Developer Sandbox
    • Explore all Developer Sandbox activities

    Ready to start developing apps?

    • Try at no cost
  • Blog
  • Events
  • Videos

How to install Red Hat Ansible Automation Platform on RHEL 9

January 1, 2023
Nagesh Rathod
Related topics:
Automation and managementLinux
Related products:
Red Hat Ansible Automation PlatformRed Hat Enterprise Linux

Share:

    Red Hat Ansible Automation Platform is a comprehensive solution that helps you automate collaboratively. In this article, you will learn how to install Ansible Automation Platform 2.2 on Red Hat Enterprise Linux 9.

    Get the Ansible Automation Platform software

    Download Ansible Automation Platform 2.2 for RHEL using this link and extract it. Upon extraction, you will see the following files:

    [user@user ~ ]$ ls
    bundle  collections  fake-inv  group_vars  images  inventory  licenses  README.md  setup.log  setup.sh

    Configure the Ansible inventory file

    The Ansible inventory file contains details about the database, credentials for PostgreSQL and Ansible, etc. For our example, we will create a single node inventory file for the Ansible Automation Platform.

    
    [automationcontroller]
    fqdn ansible_connection=local
    
    [database]
    
    [all:vars]
    admin_password='redhat'
    
    pg_host=''
    pg_port=''
    
    pg_database='awx'
    pg_username='awx'
    pg_password='redhat'

    This is a sample file; please update the parameters to match your environment.

    Ansible Automation Platform installation

    To install Ansible Automation Platform on RHEL, execute the file setup.sh in the terminal in the same directory where you have extracted the setup files.

    sudo ./setup.sh
    Using /etc/ansible/ansible.cfg as config file
    [WARNING]: running playbook inside collection
    ansible.automation_platform_installer
    [DEPRECATION WARNING]: "include" is deprecated, use include_tasks/import_tasks 
    instead. This feature will be removed in version 2.16. Deprecation warnings can
     be disabled by setting deprecation_warnings=False in ansible.cfg.
    
    PLAY [Warn if no core component is enabled] ************************************
    
    TASK [Warn if no core component is enabled] ************************************
    skipping: [localhost] => {"changed": false, "skip_reason": "Conditional result was False"}
    [WARNING]: Could not match supplied host pattern, ignoring: tower
    [WARNING]: Could not match supplied host pattern, ignoring: automationhub
    [WARNING]: Could not match supplied host pattern, ignoring: automationcatalog
    [WARNING]: Could not match supplied host pattern, ignoring: execution_nodes
    [WARNING]: Could not match supplied host pattern, ignoring: sso
    
    PLAY [Group all valid hosts for AAP installation] ******************************
    
    TASK [Gathering Facts] *********************************************************
    ok: [pqdn]
    
    TASK [group hosts used in AAP installer] ***************************************
    ok: [pqdn] => {"add_group": "aap_valid_hosts", "changed": false, "parent_groups": ["all"]}
    
    PLAY [aap_valid_hosts] *********************************************************
    
    TASK [ansible.automation_platform_installer.check_config_static : Ensure SSO node is run on a RHEL 8 node] ***
    skipping: [pqdn] => {"changed": false, "skip_reason": "Conditional result was False"}
    
    TASK [ansible.automation_platform_installer.check_config_static : Ensure expected variables are defined] ***
    skipping: [pqdn] => (item=tower_package_name)  => {"ansible_loop_var": "item", "changed": false, "item": "tower_package_name", "skip_reason": "Conditional result was False"}
    skipping: [pqdn] => (item=tower_package_version)  => {"ansible_loop_var": "item", "changed": false, "item": "tower_package_version", "skip_reason": "Conditional result was False"}
    
    TASK [ansible.automation_platform_installer.check_config_static : Ensure cluster hosts are not localhost] ***
    skipping: [pqdn] => {"changed": false, "skip_reason": "Conditional result was False"}
    
    TASK [ansible.automation_platform_installer.check_config_static : Check that group names do not conflict with instance names] ***
    skipping: [pqdn] => {"changed": false, "skip_reason": "Conditional result was False"}
    
    TASK [ansible.automation_platform_installer.check_config_static : Detect pre-2.x inventory and offer a migration] ***
    ok: [pqdn -> localhost] => {"changed": false, "msg": "Old style inventory not detected, continuing with install"}
    
    TASK [ansible.automation_platform_installer.check_config_static : Detect unsupported HA inventory file] ***
    skipping: [pqdn] => {"changed": false, "skip_reason": "Conditional result was False"}
    
    TASK [ansible.automation_platform_installer.check_config_static : Check that no instance groups are named automationcontroller] ***
    skipping: [pqdn] => (item=all)  => {"ansible_loop_var": "item", "changed": false, "item": "all", "skip_reason": "Conditional result was False"}
    skipping: [pqdn] => (item=ungrouped)  => {"ansible_loop_var": "item", "changed": false, "item": "ungrouped", "skip_reason": "Conditional result was False"}
    skipping: [pqdn] => (item=automationcontroller)  => {"ansible_loop_var": "item", "changed": false, "item": "automationcontroller", "skip_reason": "Conditional result was False"}
    skipping: [pqdn] => (item=database)  => {"ansible_loop_var": "item", "changed": false, "item": "database", "skip_reason": "Conditional result was False"}
    skipping: [pqdn] => (item=aap_valid_hosts)  => {"ansible_loop_var": "item", "changed": false, "item": "aap_valid_hosts", "skip_reason": "Conditional result was False"}
    
    TASK [ansible.automation_platform_installer.check_config_static : Ensure only one database host exists] ***
    skipping: [pqdn] => {"changed": false, "skip_reason": "Conditional result was False"}
    
    
    

    Accessing the Ansible Automation Platform Console

    After successful installation, you can access the console of the Ansible Automation platform by visiting the console URL http://localhost (Figure 1). The username is admin and the password is what you have defined in the inventory file in the [all:vars] field.

    Screenshot of the Ansible Automation Platform login page.
    Figure 1: Ansible Automation Platform login page.

    Subscriptions

    You must have valid subscriptions attached before using the Red Hat Ansible Automation Platform (Figure 2). Attaching an Ansible Automation Platform subscription enables automation hub repositories.

    Screenshot of the Ansible subscription page
    Figure 2: Ansible subscription page.

    To log in, use the same credentials you used to download Ansible Automation Platform 2.2. You can import a subscription. You can also obtain the pool_id for your Red Hat Ansible Automation Platform subscription with this command:

    $ subscription-manager list --available --all | grep "Ansible Automation Platform" -B 3 -A 6

    That command will return the following, which verifies Ansible Automation Platform entitlements:

    Subscription Name: Red Hat Ansible Automation, Premium (5000 Managed Nodes)
      Provides: Red Hat Ansible Engine
      Red Hat Ansible Automation Platform
      SKU: MCT3695
      Contract: ````
      Pool ID: ``````````
      Provides Management: No
      Available: 4999

    To attach the subscription, use the attach option with the subscription-manager command.

    # subscription-manager attach --pool=<pool_id>

    Once you've subscribed, the Red Hat Ansible Automation Platform will be attached to all nodes and able to access Automation Hub Repositories. To verify that the subscription was successfully attached, run the list option:

    # subscription-manager list --consumed

    Figure 3 gives you a glimpse of the Ansible Automation Platform web console.

    Screenshot of the Ansible Automation Platform web console.
    Figure 3: Ansible Automation Platform web console.

    Continue your automation journey with Ansible Automation Platform

    You can get started with the Ansible Automation Platform by exploring interactive labs at Red Had Developer. Ansible Automation Platform is also available as a managed offering on Microsoft Azure and as a self-managed offering on Amazon Web Services.

    Last updated: September 27, 2024

    Related Posts

    • Set up a continuous integration pipeline with Ansible Automation Platform & GitLab

    • Introducing Ansible Molecule with Ansible Automation Platform

    • Create an efficient Ansible development environment in VS Code

    • How to deploy applications using Ansible Automation Platform

    • How to use automation controller to install MS SQL

    • How to create execution environments using ansible-builder

    Recent Posts

    • Integrate Red Hat AI Inference Server & LangChain in agentic workflows

    • Streamline multi-cloud operations with Ansible and ServiceNow

    • Automate dynamic application security testing with RapiDAST

    • Assessing AI for OpenShift operations: Advanced configurations

    • OpenShift Lightspeed: Assessing AI for OpenShift operations

    What’s up next?

    Get a preview of the Red Hat Certified Engineer (RHCE) Ansible Automation Study Guide (O’Reilly), which covers key Ansible concepts for your system administration needs.

    Download the e-book
    Red Hat Developers logo LinkedIn YouTube Twitter Facebook

    Products

    • Red Hat Enterprise Linux
    • Red Hat OpenShift
    • Red Hat Ansible Automation Platform

    Build

    • Developer Sandbox
    • Developer Tools
    • Interactive Tutorials
    • API Catalog

    Quicklinks

    • Learning Resources
    • E-books
    • Cheat Sheets
    • Blog
    • Events
    • Newsletter

    Communicate

    • About us
    • Contact sales
    • Find a partner
    • Report a website issue
    • Site Status Dashboard
    • Report a security problem

    RED HAT DEVELOPER

    Build here. Go anywhere.

    We serve the builders. The problem solvers who create careers with code.

    Join us if you’re a developer, software engineer, web designer, front-end designer, UX designer, computer scientist, architect, tester, product manager, project manager or team lead.

    Sign me up

    Red Hat legal and privacy links

    • About Red Hat
    • Jobs
    • Events
    • Locations
    • Contact Red Hat
    • Red Hat Blog
    • Inclusion at Red Hat
    • Cool Stuff Store
    • Red Hat Summit

    Red Hat legal and privacy links

    • Privacy statement
    • Terms of use
    • All policies and guidelines
    • Digital accessibility

    Report a website issue