Use x-forwarded-for by default in openshift and kubernetes

This commit is contained in:
Matthew Jones 2018-01-11 11:54:28 -05:00
parent 648d27f28d
commit 7dc0fce1aa
No known key found for this signature in database
GPG Key ID: 76A4C17A97590C1C
2 changed files with 2 additions and 3 deletions

View File

@ -16,6 +16,8 @@ data:
#Autoprovisioning should replace this
CLUSTER_HOST_ID = socket.gethostname()
SYSTEM_UUID = '00000000-0000-0000-0000-000000000000'
REMOTE_HOST_HEADERS = ['HTTP_X_FORWARDED_FOR']
CELERY_TASK_QUEUES += (Queue(CLUSTER_HOST_ID, Exchange(CLUSTER_HOST_ID), routing_key=CLUSTER_HOST_ID),)
CELERY_TASK_ROUTES['awx.main.tasks.cluster_node_heartbeat'] = {'queue': CLUSTER_HOST_ID, 'routing_key': CLUSTER_HOST_ID}

View File

@ -17,9 +17,6 @@ data:
CLUSTER_HOST_ID = socket.gethostname()
SYSTEM_UUID = '00000000-0000-0000-0000-000000000000'
# Token-based authentication performs a hash check on HTTP headers expected to be consistent, including the remote host IP.
# The default OpenShift router exposes the remote host IP via the X-Forwarded-For header.
# You might have to change this setting if you use an additional reverse proxy in front of OpenShift.
REMOTE_HOST_HEADERS = ['HTTP_X_FORWARDED_FOR']
CELERY_TASK_QUEUES += (Queue(CLUSTER_HOST_ID, Exchange(CLUSTER_HOST_ID), routing_key=CLUSTER_HOST_ID),)