diff --git a/README.md b/README.md index d4e88c9c..8a6c9ca2 100644 --- a/README.md +++ b/README.md @@ -211,12 +211,13 @@ spec: #### Deploying a specific version of AWX -There are two variables that are customizable for awx the image management. +There are a few variables that are customizable for awx the image management. | Name | Description | Default | | ----------------------- | -------------------------- | ------------------ | | tower_image | Path of the image to pull | ansible/awx:15.0.0 | | tower_image_pull_policy | The pull policy to adopt | IfNotPresent | +| tower_image_pull_secret | The pull secret to use | '' | Example of customization could be: @@ -226,6 +227,7 @@ spec: ... tower_image: myorg/my-custom-awx tower_image_pull_policy: Always + tower_image_pull_secret: pull_secret_name ``` #### Privileged Tasks diff --git a/roles/installer/defaults/main.yml b/roles/installer/defaults/main.yml index f92a19e2..bfcfe5b3 100644 --- a/roles/installer/defaults/main.yml +++ b/roles/installer/defaults/main.yml @@ -57,6 +57,7 @@ tower_extra_volumes: '' tower_image: quay.io/ansible/awx:execution-environments tower_image_pull_policy: IfNotPresent +tower_image_pull_secret: '' default_ee: quay.io/ansible/awx-ee tower_create_preload_data: true diff --git a/roles/installer/templates/tower_deployment.yaml.j2 b/roles/installer/templates/tower_deployment.yaml.j2 index dffa3ea8..dccd3902 100644 --- a/roles/installer/templates/tower_deployment.yaml.j2 +++ b/roles/installer/templates/tower_deployment.yaml.j2 @@ -18,6 +18,10 @@ spec: app: '{{ deployment_type }}' spec: serviceAccountName: '{{ meta.name }}' +{% if tower_image_pull_secret %} + imagePullSecrets: + - name: {{ tower_image_pull_secret }} +{% endif %} containers: - image: '{{ tower_redis_image }}' name: redis