Merge pull request #5253 from shanemcd/stop-requiring-pg-admin-when-we-dont-need-it

Dont require pg_admin_password unless we're using it.
This commit is contained in:
Shane McDonald 2019-11-06 14:20:55 -05:00 committed by GitHub
commit 763ac25b2e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 17 additions and 3 deletions

View File

@ -84,11 +84,14 @@ pg_username=awx
# pg_password should be random 10 character alphanumeric string, when postgresql is running on kubernetes
# NB: it's a limitation of the "official" postgres helm chart
pg_password=awxpass
pg_admin_password=postgrespass
pg_database=awx
pg_port=5432
#pg_sslmode=require
# The following variable is only required when using the provided
# containerized postgres deployment on OpenShift
# pg_admin_password=postgrespass
# RabbitMQ Configuration
rabbitmq_password=awxpass
rabbitmq_erlang_cookie=cookiemonster

View File

@ -46,3 +46,10 @@
- docker_registry_password is defined and docker_registry_password != ''
msg: "Set the value of 'docker_registry_password' in the inventory file."
when: dockerhub_base is not defined
- name: pg_admin_password should be defined
assert:
that:
- pg_admin_password is defined and pg_admin_password != ''
when:
- pg_hostname is not defined or pg_hostname == ''

View File

@ -3,7 +3,9 @@ DATABASE_NAME={{ pg_database }}
DATABASE_HOST={{ pg_hostname|default('postgresql') }}
DATABASE_PORT={{ pg_port|default('5432') }}
DATABASE_PASSWORD={{ pg_password | quote }}
DATABASE_ADMIN_PASSWORD={{ pg_admin_password | quote }}
{% if pg_admin_password is defined %}
DATABASE_ADMIN_PASSWORD={{ pg_admin_password|quote }}
{% endif %}
MEMCACHED_HOST={{ memcached_hostname|default('localhost') }}
MEMCACHED_PORT={{ memcached_port|default('11211') }}
RABBITMQ_HOST={{ rabbitmq_hostname|default('localhost') }}

View File

@ -3,7 +3,9 @@ DATABASE_NAME={{ pg_database|quote }}
DATABASE_HOST={{ pg_hostname|default('postgres')|quote }}
DATABASE_PORT={{ pg_port|default('5432')|quote }}
DATABASE_PASSWORD={{ pg_password|default('awxpass')|quote }}
DATABASE_ADMIN_PASSWORD={{ pg_admin_password|default('postgrespass')|quote }}
{% if pg_admin_password is defined %}
DATABASE_ADMIN_PASSWORD={{ pg_admin_password|quote }}
{% endif %}
MEMCACHED_HOST={{ memcached_hostname|default('memcached') }}
MEMCACHED_PORT={{ memcached_port|default('11211')|quote }}
RABBITMQ_HOST={{ rabbitmq_hostname|default('rabbitmq')|quote }}