修改代理路径
This commit is contained in:
parent
1ffedd8eea
commit
3dc1faf896
@ -2,5 +2,4 @@
|
||||
ENV = production
|
||||
|
||||
# 线上环境接口地址
|
||||
# VITE_API_URL = http://8.138.175.106/
|
||||
VITE_API_URL = http://8.138.171.103/
|
@ -16,8 +16,8 @@ const alias: Record<string, string> = {
|
||||
};
|
||||
|
||||
// 请求映射后端路径
|
||||
// const url:string = 'http://8.138.171.103';
|
||||
const url:string = 'http://localhost:8081';
|
||||
const url:string = 'http://8.138.171.103';
|
||||
// const url:string = 'http://localhost:8081';
|
||||
|
||||
const viteConfig = defineConfig((mode: ConfigEnv) => {
|
||||
const env = loadEnv(mode.mode, process.cwd());
|
||||
@ -39,7 +39,7 @@ const viteConfig = defineConfig((mode: ConfigEnv) => {
|
||||
ws: true,
|
||||
secure: false,
|
||||
changeOrigin: true,
|
||||
rewrite: (path) => path.replace(/^\/aerocraftAdminApi/, ''),
|
||||
// rewrite: (path) => path.replace(/^\/aerocraftAdminApi/, ''),
|
||||
},
|
||||
'/upload': {
|
||||
target: url,
|
||||
|
Loading…
Reference in New Issue
Block a user