修复工作
This commit is contained in:
@@ -10,9 +10,9 @@ server {
|
||||
try_files $uri $uri/ /index.html;
|
||||
}
|
||||
|
||||
# 后端API代理(backend使用host网络)
|
||||
# 后端API代理(backend使用host网络,暴露10082端口)
|
||||
location /prod-api/ {
|
||||
proxy_pass http://127.0.0.1:8080/;
|
||||
proxy_pass http://127.0.0.1:10082/;
|
||||
proxy_set_header Host $host;
|
||||
proxy_set_header X-Real-IP $remote_addr;
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
@@ -24,7 +24,7 @@ server {
|
||||
|
||||
# WebSocket支持(用于视频流)
|
||||
location /websocket/ {
|
||||
proxy_pass http://127.0.0.1:8080/websocket/;
|
||||
proxy_pass http://127.0.0.1:10082/websocket/;
|
||||
proxy_http_version 1.1;
|
||||
proxy_set_header Upgrade $http_upgrade;
|
||||
proxy_set_header Connection "upgrade";
|
||||
@@ -45,9 +45,9 @@ server {
|
||||
proxy_set_header X-Forwarded-Proto $scheme;
|
||||
}
|
||||
|
||||
# 视频流代理(HTTP-FLV,backend使用host网络)
|
||||
# 视频流代理(HTTP-FLV,backend使用host网络,暴露10083端口)
|
||||
location /live {
|
||||
proxy_pass http://127.0.0.1:8866;
|
||||
proxy_pass http://127.0.0.1:10083;
|
||||
proxy_http_version 1.1;
|
||||
|
||||
# 重要:禁用所有缓冲,实时传输视频流
|
||||
@@ -75,7 +75,7 @@ server {
|
||||
|
||||
# 视频流代理(HLS)
|
||||
location /hls {
|
||||
proxy_pass http://127.0.0.1:8866;
|
||||
proxy_pass http://127.0.0.1:10083;
|
||||
proxy_http_version 1.1;
|
||||
|
||||
# HLS也需要禁用缓冲
|
||||
|
||||
Reference in New Issue
Block a user