By default, the installer for AWX will create the awx_default network (bridge) in docker and will provide a network for that bridge (such as 172.18.0.0/16). Under certain circumstances, it can happen that these networks overlap and you might need to adjust this network. One solution is to create the network beforehand before starting the installer with your dedicated container network
A note on AWX: Versions are not inter-upgradeable so it's best practice to have your job_templates, projects, inventories, credentials and so on in a dedicated git repository where you can easily deploy it using ansible or any other configuration management tool. I've also had bad luck with backing up the config and restoring it.
If you have already provisioned your AWX, you'll need to start by stopping and removing the containers as well as the networks.
[root@awx ~]# docker container stop awx_task awx_web awx_redis awx_memcached awx_postgresql
[root@awx ~]# docker container rm awx_task awx_web awx_redis awx_memcached awx_postgresql
[root@awx ~]# docker network rm awx_default
Also, empty out the folders for your projects, PostgreSQL and docker-compose. These paths can be custom set in the installer's inventory.
[root@awx ~]# rm -rf /var/lib/awx/postgresql/
[root@awx ~]# rm -rf /var/lib/awx/projects/
[root@awx ~]# rm -rf /var/lib/docker/awx/
Now that we have a clean environment, start by creating the network for AWX
[root@awx ~]# docker network create --subnet 169.254.0.0/16 awx_default
The containers created by the installer will now have addresses from the 169.254.0.0/16 range. They shouldn't be interfering with any already existing network that way. With that being done, you can just start the installer again and provision your instance of AWX.
Feel free to comment and / or suggest a topic.
Comments
Post a Comment