🔥 refactor(nginx.conf): remove redundant code for proxying /api/v1/ and /health routes to backend service

This commit is contained in:
Gabriel Luiz Freitas Almeida 2023-08-20 23:38:47 -03:00
commit 9baf588e5e

View file

@ -15,21 +15,6 @@ server {
try_files $uri $uri/ /index.html =404;
}
location ~ ^/api/v1/ { # Matching the /api/v1/ route
proxy_pass __BACKEND_URL__; # URL of your backend service
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection 'upgrade';
proxy_set_header Host $host;
proxy_cache_bypass $http_upgrade;
}
location /health { # Matching the /health route
proxy_pass __BACKEND_URL__; # URL of your backend service
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection 'upgrade';
proxy_set_header Host $host;
proxy_cache_bypass $http_upgrade;
}
include /etc/nginx/extra-conf.d/*.conf;
}