NOTE: it seems that somebody else beat me to this, so I'm not going to finish this
https://qiita.com/ussvgr/items/81b88653b2845b0f1bea
Prerequisites:
- An ARM64 machine with Ansible and Docker installed to build the images on. This doesn't necessarily need to be the same machine that you're going to deploy AWX on. Considering using something like an AWS Graviton2-based EC2 instance to cut down on image build time
- A Docker registry to push the custom images to
- A Kubernetes cluster on ARM64 to deploy on
Steps:
- Clone the https://github.com/ansible/awx repo on your ARM64 machine
- Checkout the tag of the latest AWX release (e.g.
19.3.0
) - Build the AWX image. This will take a while (it took ~80 minutes on my RasPi 4)
$ ansible-playbook tools/ansible/build.yml -v -e awx_image=<registry>/<prefix>/awx
- Push the image to the registry
$ docker push <registry>/<prefix>/awx:<version>
- Clone the https://github.com/ansible/awx-operator repo on your ARM64 machine
- Checkout the tag of the latest release (e.g.
0.13.0
) - Build the awx-operator image
$ docker build -t <registry>/<prefix>/awx-operator:<version> -f build/Dockerfile .
- Push the image to the registry
$ docker push <registry>/<prefix>/awx-operator:<version>
- Fetch the awx-operator install manifest
$ wget https://raw.githubusercontent.com/ansible/awx-operator/<version>/deploy/awx-operator.yaml
- Replace the
image
value in theDeployment
resource with your custom image
$ sed -i 's|quay.io/ansible/awx-operator:[0-9.]\+|<registry>/<prefix>/awx-operator:<version>|' awx-operator.yaml
- Apply the modified manifest
$ kubectl apply -f awx-operator.yaml
- Create your AWX manifest and specify the custom image
---
apiVersion: awx.ansible.com/v1beta1
kind: AWX
metadata:
name: awx-demo
spec:
...
image: <registry>/<prefix>/awx
image_version: <version>
...
- Apply the manifest
$ kubectl apply -f awx.yaml