summaryrefslogtreecommitdiffstats
path: root/tools/docker-compose/ansible/roles/sources/templates/nginx.locations.conf.j2
diff options
context:
space:
mode:
Diffstat (limited to 'tools/docker-compose/ansible/roles/sources/templates/nginx.locations.conf.j2')
-rw-r--r--tools/docker-compose/ansible/roles/sources/templates/nginx.locations.conf.j28
1 files changed, 8 insertions, 0 deletions
diff --git a/tools/docker-compose/ansible/roles/sources/templates/nginx.locations.conf.j2 b/tools/docker-compose/ansible/roles/sources/templates/nginx.locations.conf.j2
index fd2b89a691..404be4ade2 100644
--- a/tools/docker-compose/ansible/roles/sources/templates/nginx.locations.conf.j2
+++ b/tools/docker-compose/ansible/roles/sources/templates/nginx.locations.conf.j2
@@ -38,4 +38,12 @@ location {{ ingress_path }} {
uwsgi_read_timeout 120s;
uwsgi_pass uwsgi;
include /etc/nginx/uwsgi_params;
+ error_page 502 = @fallback;
+}
+
+# Enable scenario where we shutdown uwsgi and launching runserver for debugging purposes
+location @fallback {
+ # Add trailing / if missing
+ rewrite ^(.*)$http_host(.*[^/])$ $1$http_host$2/ permanent;
+ proxy_pass http://runserver;
}