|
@@ -1,3 +1,8 @@
|
|
|
|
+upstream backed_server {
|
|
|
|
+ server 192.168.6.251:8080 max_fails=1 fail_timeout=10s;
|
|
|
|
+ server 192.168.3.251:8080 max_fails=1 fail_timeout=10s;
|
|
|
|
+}
|
|
|
|
+
|
|
server {
|
|
server {
|
|
listen 80;
|
|
listen 80;
|
|
server_name localhost;
|
|
server_name localhost;
|
|
@@ -19,6 +24,16 @@ server {
|
|
index start.html index.html;
|
|
index start.html index.html;
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+ location /api {
|
|
|
|
+ proxy_read_timeout 300;
|
|
|
|
+ proxy_pass http://backed_server;
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ location /ws {
|
|
|
|
+ proxy_read_timeout 300;
|
|
|
|
+ proxy_pass http://backed_server;
|
|
|
|
+ }
|
|
|
|
+
|
|
# location /api {
|
|
# location /api {
|
|
# proxy_read_timeout 300;
|
|
# proxy_read_timeout 300;
|
|
# proxy_pass http://192.168.3.177:8080;
|
|
# proxy_pass http://192.168.3.177:8080;
|