fix: 补全前端容器公共 API 代理

- 将 /flow/public-api/ 请求转发到后端 /public-api/

- 保持工作流等公共接口的同源访问路径
This commit is contained in:
2026-08-31 13:46:54 +08:00
parent e6b2e2798f
commit 17ef189862

View File

@@ -94,6 +94,26 @@ http {
proxy_redirect off;
}
location ^~ /flow/public-api/ {
set $easyflow_backend http://backend:8111;
rewrite ^/flow/public-api/(.*)$ /public-api/$1 break;
proxy_pass $easyflow_backend;
proxy_http_version 1.1;
proxy_set_header Connection "";
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_set_header X-Forwarded-Port $server_port;
proxy_set_header X-Forwarded-Prefix /flow;
proxy_read_timeout 3600s;
proxy_send_timeout 3600s;
proxy_buffering off;
proxy_cache off;
proxy_redirect off;
}
location ^~ /flow/storage/ {
set $easyflow_minio http://minio-shared:9000;
rewrite ^/flow/storage/(.*)$ /easyflow/$1 break;