Former-commit-id: e69f98468002153548426f427c3325638f20b539 Former-commit-id: 4fa2dcbef15dbd6e01e3e22cdd191da347539620TangShanKaiPing
parent
b44db23b09
commit
8168e857ab
@ -1,80 +1,78 @@
|
||||
#user nobody;
|
||||
worker_processes 1;
|
||||
worker_processes 1;
|
||||
|
||||
#error_log logs/error.log;
|
||||
#error_log logs/error.log notice;
|
||||
#error_log logs/error.log info;
|
||||
|
||||
#pid logs/nginx.pid;
|
||||
|
||||
|
||||
events {
|
||||
worker_connections 1024;
|
||||
worker_connections 1024;
|
||||
}
|
||||
|
||||
|
||||
http {
|
||||
include mime.types;
|
||||
default_type application/octet-stream;
|
||||
include mime.types;
|
||||
default_type application/octet-stream;
|
||||
|
||||
sendfile on;
|
||||
sendfile on;
|
||||
|
||||
keepalive_timeout 65;
|
||||
keepalive_timeout 65;
|
||||
|
||||
server {
|
||||
listen 0.0.0.0:80;
|
||||
server_name localhost;
|
||||
|
||||
location / {
|
||||
#proxy_set_header Host $host:$server_port;
|
||||
if ($http_user_agent ~* "(mobile|android|ipad|iphone|ipod|tablet)") {
|
||||
proxy_pass http://localhost:5002;
|
||||
break;
|
||||
}
|
||||
proxy_pass http://localhost:5001/;
|
||||
}
|
||||
listen 0.0.0.0:80;
|
||||
server_name localhost;
|
||||
|
||||
location / {
|
||||
#proxy_set_header Host $host:$server_port;
|
||||
if ($http_user_agent ~* "(mobile|android|ipad|iphone|ipod|tablet)") {
|
||||
proxy_pass http://localhost:5002;
|
||||
break;
|
||||
}
|
||||
proxy_pass http://localhost:5001/;
|
||||
}
|
||||
|
||||
location ^~ /dfs/ {
|
||||
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_pass http://localhost:9000/;
|
||||
}
|
||||
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_pass http://localhost:9000/;
|
||||
}
|
||||
|
||||
location ^~ /live/ {
|
||||
proxy_pass http://localhost:8080/live/;
|
||||
}
|
||||
proxy_pass http://localhost:8080/live/;
|
||||
}
|
||||
|
||||
location ^~ /video/ {
|
||||
proxy_pass http://localhost:8080/video/;
|
||||
}
|
||||
proxy_pass http://localhost:8080/video/;
|
||||
}
|
||||
|
||||
location ^~ /influxdb/ {
|
||||
location ^~ /influxdb/ {
|
||||
proxy_pass http://localhost:8086/;
|
||||
}
|
||||
|
||||
location ^~ /UserCenter/ {
|
||||
proxy_pass http://localhost:8010/UserCenter/;
|
||||
}
|
||||
proxy_pass http://localhost:8010/UserCenter/;
|
||||
}
|
||||
|
||||
location ^~ /IoTCenter/ {
|
||||
proxy_pass http://localhost:8011/IoTCenter/;
|
||||
}
|
||||
proxy_pass http://localhost:8011/IoTCenter/;
|
||||
}
|
||||
|
||||
location ^~ /IoTCenter/hub {
|
||||
proxy_pass http://localhost:8011/IoTCenter/hub;
|
||||
proxy_http_version 1.1;
|
||||
proxy_set_header Upgrade $http_upgrade;
|
||||
proxy_set_header Connection "upgrade";
|
||||
}
|
||||
proxy_pass http://localhost:8011/IoTCenter/hub;
|
||||
proxy_http_version 1.1;
|
||||
proxy_set_header Upgrade $http_upgrade;
|
||||
proxy_set_header Connection "upgrade";
|
||||
}
|
||||
|
||||
location ^~ /JobServer/ {
|
||||
proxy_pass http://localhost:8013/JobServer/;
|
||||
}
|
||||
proxy_pass http://localhost:8013/JobServer/;
|
||||
}
|
||||
|
||||
error_page 500 502 503 504 /50x.html;
|
||||
error_page 500 502 503 504 /50x.html;
|
||||
location = /50x.html {
|
||||
root html;
|
||||
root html;
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Reference in new issue