admin: proxy /api/v1/proc to Rust htyproc (same as v2)

Made-with: Cursor
This commit is contained in:
2026-04-26 21:25:34 +08:00
parent 23ce2eff19
commit 9ab2ae4753
2 changed files with 17 additions and 0 deletions
+8
View File
@@ -112,6 +112,14 @@ server {
proxy_pass http://127.0.0.1:3000/api/v1/uc/;
}
location /api/v1/proc/ {
proxy_pass http://$huiwing_htyproc_rust/api/v1/proc/;
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;
}
# 同域独立测 Rust TS/proc(不经 ts./proc. 子域);/api/v2 → 本机 htyts/htyproc
location /api/v2/ts/ {
proxy_pass http://$huiwing_htyts_rust/api/v1/ts/;
+9
View File
@@ -136,6 +136,15 @@ server {
proxy_pass http://127.0.0.1:3000/api/v1/uc/;
}
# 管理端历史路径 /api/v1/proc/*(与 /api/v2/proc/ 同 upstream Rust htyproc
location /api/v1/proc/ {
proxy_pass http://$huiwing_htyproc_rust/api/v1/proc/;
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;
}
location /api/v2/ts/ {
rewrite ^/api/v2/ts/$ /api/v1/ts break;
rewrite ^/api/v2/ts/(.+)$ /api/v1/ts/$1 break;