Installation Deployment Ansible AWX on CentOS 7 - PandaM0nium/AWX GitHub Wiki

Ansible AWX deployment on CentOS 7

Install CentOS 7

Installing packages

Installing python 3.6 and pip packages

yum install centos-release-scl

yum install rh-python36

yum install -y epel-release

yum install python-pip

easy_install pip

Reduced version of pip and install pip packages

pip install --upgrade --force-reinstall pip==9.0.3

pip install cryptography --disable-pip-version-check

pip install jsonschema --disable-pip-version-check

pip install docker-compose~=1.23.0 --disable-pip-version-check

pip install docker --disable-pip-version-check

Upgrade pip back to latest release

pip install --upgrade pip

Install Docker/AWX pre-req packages

yum install -y yum-utils device-mapper-persistent-data lvm2 ansible git python-devel python-pip python-docker-py vim-enhanced

Add Docker CE repository and install Docker-CE

yum-config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo

yum install docker-ce -y

Start and enable Docker

systemctl start docker

systemctl enable docker

Clone AWX repo from git and set up config

git clone https://github.com/ansible/awx.git

cd awx/

git clone https://github.com/ansible/awx-logos.git

cd installer/

vim inventory

modify the follwing section within inventory and save

 * awx_official=true

 * project_data_dir=/var/lib/awx/projects

 * postgres_data_dir=/var/lib/pgdocker

 * docker_compose_dir=/var/lib/awx

Open up firewall for http and https access

firewall-cmd --zone=public --add-masquerade --permanent

firewall-cmd --permanent --add-service=http

firewall-cmd --permanent --add-service=https

firewall-cmd --reload

Run ansible playbook to deploy awx

ansible-playbook -i inventory install.yml -vv

navigate to http://localhost or http:// to access AWX

username: admin

password: password

Troubleshooting steps

Most likely, the page will get stuck at "AWX is upgrading loop". This is a known problem which many people have to deal with. To fix this problem perform the following procedure.

stop docker container by

  • docker restart awx_task

  • docker restart awx_web

  • docker restart awx_postgres

  • docker restart awx_memcached

  • docker restart awx_redis

then

run install.yml again

⚠️ **GitHub.com Fallback** ⚠️