chore: initial project scaffold: nginx/nginx.conf
This commit is contained in:
23
nginx/nginx.conf
Normal file
23
nginx/nginx.conf
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
resolver 127.0.0.11 valid=10s;
|
||||||
|
|
||||||
|
server {
|
||||||
|
listen 80;
|
||||||
|
server_name toir-light-v11.greact.ru;
|
||||||
|
|
||||||
|
location /api/ {
|
||||||
|
set $backend http://toir-light-v11-backend:3000;
|
||||||
|
rewrite ^/api/(.*)$ /$1 break;
|
||||||
|
proxy_pass $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;
|
||||||
|
proxy_set_header X-Forwarded-Proto $scheme;
|
||||||
|
}
|
||||||
|
|
||||||
|
location / {
|
||||||
|
set $frontend http://toir-light-v11-frontend:80;
|
||||||
|
proxy_pass $frontend;
|
||||||
|
proxy_set_header Host $host;
|
||||||
|
proxy_set_header X-Real-IP $remote_addr;
|
||||||
|
}
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user