Installing Ansible AWX 12 on IBM Power

It took me a lot of time to port Ansible AWX to ppc64le Linux. The most amazing thing - it works after all! Here I will describe some steps you need to start AWX on CentOS 7 or Red Hat Enterprise Linux 7 and the differencies between them.


You can see the whole process of the installation on Youtube.


First of all you need a fresh installed CentOS7 or RHEL7. On RHEL7 you must enable the following repositories:



subscription-manager repos --enable rhel-7-server-for-power-le-rhscl-rpms


and install EPEL:



yum install https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm


You must do the same on CentOS7, but with different commands:



yum -y install epel-release centos-release-scl-rh


CentOS 7 is missing one of the required packages - postgresql10-runtime. It is present in the RHEL 7 repository and in CentOS 7 x86_64 repository, but not in CentOS 7 ppc64le repo. You can download it from my site:



yum -y install https://dl.power-devops.com/repo/el7/rh-postgresql10-runtime-3.1-1.el7.ppc64le.rpm


At this step we are ready to install Ansible AWX. The installation and configuraiton are the same on CentOS7 and RHEL7. First install the package:



yum install https://dl.power-devops.com/ansible-awx-12.0.0-1.el7.ppc64le.rpm


The installation takes some time because of many dependencies, AWX has. After the installation is finished, we can configure the system to start AWX.


I switch off the firewall and SELinux. As for firewall it is up to you, if you want to switch it off, but I highly recommend to switch off SELinux. I don't have any SELinux policies in the package and if you turn it on, you have to write a policy on your own.



systemctl stop firewalld 
systemctl disable firewalld 
setenforce 0 


Edit /etc/selinux/config and change SELINUX variable to disabled.


Ansible AWX works with redis through UNIX socket. That's why we must enable UNIX socket in Redis configuration and set the correct permissions on it. Open the file /etc/redis.conf, find the following two lines and change them accordingly.



unixsocket /var/run/redis/redis.sock
unixsocketperm 775


We also have to set permissions on supervisord runtime directory:



chmod 0755 /var/run/supervisor


and add nginx user to awx group, in order nginx web server can serve awx pages:



usermod -G awx nginx


Now let's initialize PostgreSQL.



scl enable rh-postgresql10 bash
postgresql-setup initdb


After the initialization we start it and look if it works.



systemctl start rh-postgresql10-postgresql
systemctl enable rh-postgresql10-postgresql
systemctl status rh-postgresql10-postgresql


PostgreSQL works and we can create the database. First create the awx user and the awx database, owned by the user.



su - postgres
scl enable rh-postgresql10 bash
createuser -S awx
createdb -O awx awx


As we have the database, we can create the tables now.



su - awx
awx-manage migrate


It takes some time, almost as long as the installation of AWX. When it is finished, we create our AWX administrator:



awx-manage createsuperuser --username admin --email root@localhost


The final steps are to load some sample data and provision the AWX instance:



awx-manage create_preload_data
awx-manage provision_instance --hostname=$(hostname)
awx-manage register_queue --queuename=tower --hostnames=$(hostname)


We also must change CLUSTER_HOST_ID in /etc/tower/settings.py to our hostname. Otherwise ansible doesn't work.


Now we are ready to start AWX.


systemctl enable ansible-awx
systemctl start ansible-awx


Check that all services are up and running:



systemctl status rh-postgresql10-postgresql
systemctl status redis
systemctl status nginx
systemctl status supervisord


If all of them are up and running, you are ready to go to your browser and enjoy your new AWX installation!

128 views2 comments
  • YouTube
  • Black Facebook Icon

©2019-2020 by Power-Devops.com