Skip to content

Commit

Permalink
Only ignore redis errors in management pod
Browse files Browse the repository at this point in the history
  • Loading branch information
shanemcd authored and rebeccahhh committed Jun 8, 2020
1 parent e77ca20 commit fbe1736
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 4 deletions.
1 change: 0 additions & 1 deletion awx/settings/defaults.py
Original file line number Diff line number Diff line change
Expand Up @@ -439,7 +439,6 @@ def IS_TESTING(argv=None):
}

# Django Caching Configuration
DJANGO_REDIS_IGNORE_EXCEPTIONS = True
CACHES = {
'default': {
'BACKEND': 'django_redis.cache.RedisCache',
Expand Down
2 changes: 2 additions & 0 deletions installer/roles/kubernetes/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -246,6 +246,8 @@

- name: Migrate database
shell: |
{{ kubectl_or_oc }} -n {{ kubernetes_namespace }} exec ansible-tower-management -- \
bash -c "echo 'DJANGO_REDIS_IGNORE_EXCEPTIONS = True' > /etc/tower/conf.d/redis.py"
{{ kubectl_or_oc }} -n {{ kubernetes_namespace }} exec ansible-tower-management -- \
bash -c "awx-manage migrate --noinput"
Expand Down
8 changes: 7 additions & 1 deletion installer/roles/kubernetes/templates/management-pod.yml.j2
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,13 @@ spec:
readOnly: true

- name: "{{ kubernetes_deployment_name }}-application-credentials"
mountPath: "/etc/tower/conf.d/"
mountPath: "/etc/tower/conf.d/environment.sh"
subPath: environment.sh
readOnly: true

- name: "{{ kubernetes_deployment_name }}-application-credentials"
mountPath: "/etc/tower/conf.d/credentials.py"
subPath: credentials.py
readOnly: true

- name: {{ kubernetes_deployment_name }}-secret-key
Expand Down
3 changes: 1 addition & 2 deletions tools/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,7 @@ services:
volumes:
- "../:/awx_devel"
- "../awx/projects/:/var/lib/awx/projects/"
- "./redis/redis_socket_standalone:/var/run/redis/"
- "./rsyslog/:/var/lib/awx/rsyslog"
- "./redis/redis_socket_standalone:/var/run/redis/"
- "./docker-compose/supervisor.conf:/etc/supervisord.conf"
privileged: true
tty: true
Expand Down

0 comments on commit fbe1736

Please sign in to comment.