diff --git a/docker/nginx/conf.d/default.conf b/docker/nginx/conf.d/default.conf index d3924cecd..9221071ad 100644 --- a/docker/nginx/conf.d/default.conf +++ b/docker/nginx/conf.d/default.conf @@ -18,14 +18,14 @@ server { listen 3001; - location / { - root /usr/share/nginx/html/platfrom; + location / { + root /usr/share/nginx/html/platform; index index.html index.htm; try_files $uri $uri/ /index.html =404; add_header X-Frame-Options SAMEORIGIN; } - location /api { + location /api { proxy_pass http://backend:7860; proxy_read_timeout 300s; proxy_set_header Host $host; @@ -39,13 +39,14 @@ server { add_header X-Frame-Options SAMEORIGIN; } - location /workbench/ { + location /workspace/ { alias /usr/share/nginx/html/client/; index index.html index.htm; - try_files $uri $uri/ /workbench/index.html; + try_files $uri $uri/ /workspace/index.html; } - location /workbench/api { - rewrite ^/workbench(/.*)$ $1 break; + + location /workspace/api { + rewrite ^/workspace(/.*)$ $1 break; proxy_pass http://backend:7860; proxy_set_header Host $host; proxy_set_header X-Real-IP $remote_addr; @@ -58,8 +59,8 @@ server { add_header X-Frame-Options SAMEORIGIN; } - - location ~ ^/(workbench/bisheng|bisheng|tmp-dir)/ { + location ~ ^/(workspace/bisheng|bisheng|tmp-dir)/ { + rewrite ^/workspace(/.*)$ $1 break; proxy_pass http://minio:9000; } } \ No newline at end of file diff --git a/src/frontend/nginx.conf b/src/frontend/nginx.conf index 1e1328682..714ad450a 100644 --- a/src/frontend/nginx.conf +++ b/src/frontend/nginx.conf @@ -19,7 +19,7 @@ server { listen 3001; location / { - root /usr/share/nginx/html/platfrom; + root /usr/share/nginx/html/platform; index index.html index.htm; try_files $uri $uri/ /index.html =404; add_header X-Frame-Options SAMEORIGIN; diff --git a/src/frontend/platform/src/pages/BuildPage/bench/ModelManagement.tsx b/src/frontend/platform/src/pages/BuildPage/bench/ModelManagement.tsx index 1dd6d4074..cca5e27cb 100644 --- a/src/frontend/platform/src/pages/BuildPage/bench/ModelManagement.tsx +++ b/src/frontend/platform/src/pages/BuildPage/bench/ModelManagement.tsx @@ -51,12 +51,18 @@ export const ModelManagement = ({
- {llmOptions.length > 1 && 0 ? onModelChange(index, val)} + /> : {}} />} {errors[model.key] &&

{errors[model.key]?.[0]}

}
diff --git a/src/frontend/platform/vite.config.mts b/src/frontend/platform/vite.config.mts index b26a6172d..8b96a61f0 100644 --- a/src/frontend/platform/vite.config.mts +++ b/src/frontend/platform/vite.config.mts @@ -7,8 +7,7 @@ import svgr from "vite-plugin-svgr"; // import { visualizer } from 'rollup-plugin-visualizer'; // Use environment variable to determine the target. -// const target = process.env.VITE_PROXY_TARGET || "http://127.0.0.1:7860"; - const target = process.env.VITE_PROXY_TARGET || "http://192.168.106.120:3002"; + const target = process.env.VITE_PROXY_TARGET || "http://127.0.0.1:7860"; const apiRoutes = ["^/api/", "/health"]; const proxyTargets = apiRoutes.reduce((proxyObj, route) => {