replace host
This commit is contained in:
+5
-5
@@ -1,7 +1,7 @@
|
|||||||
server {
|
server {
|
||||||
# set $servername "test-music-room.moicen.com";
|
# set $servername "test-music-room.moicen.com";
|
||||||
# set $servername "localhost";
|
# set $servername "localhost";
|
||||||
set $servername "test-music-room.moicen.com";
|
# set $servername "test-music-room.moicen.com";
|
||||||
# https://serverfault.com/questions/798734/use-variable-for-server-name-in-nginx#
|
# https://serverfault.com/questions/798734/use-variable-for-server-name-in-nginx#
|
||||||
# server_name $servername;
|
# server_name $servername;
|
||||||
server_name "test-music-room.moicen.com";
|
server_name "test-music-room.moicen.com";
|
||||||
@@ -20,7 +20,7 @@ server {
|
|||||||
|
|
||||||
location / {
|
location / {
|
||||||
try_files $uri $uri/ /index.html;
|
try_files $uri $uri/ /index.html;
|
||||||
proxy_set_header Host $servername;
|
proxy_set_header Host "test-music-room.moicen.com";
|
||||||
proxy_set_header X-Real-IP $remote_addr;
|
proxy_set_header X-Real-IP $remote_addr;
|
||||||
# disable in local test env
|
# disable in local test env
|
||||||
proxy_set_header X-Forwarded-Proto https;
|
proxy_set_header X-Forwarded-Proto https;
|
||||||
@@ -50,15 +50,15 @@ server {
|
|||||||
|
|
||||||
location /api/v1/ws/ {
|
location /api/v1/ws/ {
|
||||||
proxy_pass http://127.0.0.1:3001/api/v1/ws/;
|
proxy_pass http://127.0.0.1:3001/api/v1/ws/;
|
||||||
proxy_set_header Host $host;
|
proxy_set_header Host "test-music-room.moicen.com";
|
||||||
}
|
}
|
||||||
location /api/v1/uc/ {
|
location /api/v1/uc/ {
|
||||||
proxy_pass http://127.0.0.1:3000/api/v1/uc/;
|
proxy_pass http://127.0.0.1:3000/api/v1/uc/;
|
||||||
proxy_set_header Host $host;
|
proxy_set_header Host "test-music-room.moicen.com";
|
||||||
}
|
}
|
||||||
location /api/v1/ts/ {
|
location /api/v1/ts/ {
|
||||||
proxy_pass http://127.0.0.1:8080/api/v1/ts/;
|
proxy_pass http://127.0.0.1:8080/api/v1/ts/;
|
||||||
proxy_set_header Host $host;
|
proxy_set_header Host "test-music-room.moicen.com";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user