Merge pull request #1089 from nagisa77/codex/update-.env.example-for-openisle_mcp_port

Configure MCP proxy routes
This commit is contained in:
Tim
2025-10-26 14:26:35 +08:00
committed by GitHub
3 changed files with 42 additions and 1 deletions

View File

@@ -2,6 +2,7 @@
SERVER_PORT=8080 SERVER_PORT=8080
FRONTEND_PORT=3000 FRONTEND_PORT=3000
WEBSOCKET_PORT=8082 WEBSOCKET_PORT=8082
OPENISLE_MCP_PORT=8085
MYSQL_PORT=3306 MYSQL_PORT=3306
REDIS_PORT=6379 REDIS_PORT=6379
RABBITMQ_PORT=5672 RABBITMQ_PORT=5672

View File

@@ -119,6 +119,26 @@ server {
proxy_cache off; proxy_cache off;
add_header Cache-Control "no-store" always; add_header Cache-Control "no-store" always;
} }
location ^~ /mcp/ {
proxy_pass http://127.0.0.1:8085/;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection $connection_upgrade;
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 X-Forwarded-Host $host;
proxy_read_timeout 300s;
proxy_send_timeout 300s;
proxy_buffering off;
proxy_cache off;
add_header Cache-Control "no-store" always;
}
} }
server { server {

View File

@@ -80,4 +80,24 @@ server {
add_header Cache-Control "no-store" always; add_header Cache-Control "no-store" always;
} }
location ^~ /mcp/ {
proxy_pass http://127.0.0.1:8086/;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection $connection_upgrade;
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 X-Forwarded-Host $host;
proxy_read_timeout 300s;
proxy_send_timeout 300s;
proxy_buffering off;
proxy_cache off;
add_header Cache-Control "no-store" always;
}
} }