@ -1,54 +1,50 @@
server {
listen 80;
server_name localhost;
proxy_http_version 1.1;
location / {
proxy_pass ${FRONT_PROXY_PASS};
}
location /socket/v2 {
proxy_pass http://backend:4000;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "Upgrade";
proxy_set_header Host $host;
}
location /api/ {
proxy_pass http://backend:4000/api;
}
map $http_upgrade $connection_upgrade {
default upgrade;
'' close;
}
server {
listen 81 ;
listen 80;
server_name localhost;
proxy_http_version 1.1;
proxy_hide_header Access-Control-Allow-Origin;
proxy_hide_header Access-Control-Allow-Methods;
add_header 'Access-Control-Allow-Origin' 'http://localhost' always;
add_header 'Access-Control-Allow-Methods' 'PUT, GET, POST, OPTIONS, DELETE, PATCH' always;
location / {
proxy_pass http://backend:4000;
proxy_pass http://backend:4000;
proxy_http_version 1.1;
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";
proxy_set_header Upgrade "$http_upgrade";
proxy_set_header Connection $connection_upgrade;
proxy_cache_bypass $http_upgrade;
}
location /auth {
proxy_pass http://backend:4000;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "Upgrade";
proxy_set_header Host $host;
location = / {
proxy_pass ${FRONT_PROXY_PASS};
proxy_http_version 1.1;
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";
proxy_set_header Upgrade "$http_upgrade";
proxy_set_header Connection $connection_upgrade;
proxy_cache_bypass $http_upgrade;
}
location /socket {
proxy_pass http://backend:4000;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "Upgrade";
proxy_set_header Host $host;
location ~ ^/(_next|node-api|apps|account|accounts|static|auth/profile|auth/unverified-email|txs|tx|blocks|block|login|address|stats|search-results|token|tokens|visualize|api-docs|csv-export|verified-contracts|graphiql|withdrawals) {
proxy_pass ${FRONT_PROXY_PASS};
proxy_http_version 1.1;
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";
proxy_set_header Upgrade "$http_upgrade";
proxy_set_header Connection $connection_upgrade;
proxy_cache_bypass $http_upgrade;
}
}
server {
listen 82 ;
listen 8080 ;
server_name localhost;
proxy_http_version 1.1;
proxy_hide_header Access-Control-Allow-Origin;
@ -58,13 +54,14 @@ server {
add_header 'Access-Control-Allow-Methods' 'PUT, GET, POST, OPTIONS, DELETE, PATCH' always;
location / {
proxy_pass http://stats:8050;
}
location /socket/v2 {
proxy_pass http://backend:4000;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "Upgrade";
proxy_set_header Host $host;
proxy_pass http://stats:8050;
proxy_http_version 1.1;
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";
proxy_set_header Upgrade "$http_upgrade";
proxy_set_header Connection $connection_upgrade;
proxy_cache_bypass $http_upgrade;
}
}