From 87b4a25aa65944819c06b875d9de2e94f9a1af3a Mon Sep 17 00:00:00 2001 From: Pavle Portic Date: Tue, 26 Mar 2019 05:01:12 +0100 Subject: [PATCH] Update nginx config to redirect /admin to django --- nginx.conf | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/nginx.conf b/nginx.conf index 3b592d3..b045872 100644 --- a/nginx.conf +++ b/nginx.conf @@ -3,14 +3,7 @@ server { server_name _; client_max_body_size 5M; - location /api/ { - proxy_pass http://perktree-backend; - proxy_set_header Host $host; - proxy_set_header X-Real-IP $remote_addr; - proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; - } - - location /django-static { + location ~ ^/(api|django-static|admin) { proxy_pass http://perktree-backend; proxy_set_header Host $host; proxy_set_header X-Real-IP $remote_addr;