salpa-web/config/proxy.ts
2023-12-28 09:59:34 +08:00

48 lines
1.1 KiB
TypeScript

/*
* @version: V1.0.0
* @Date: 2023-12-26 13:54:58
* @LastEditors: lzq
* @LastEditTime: 2023-12-26 14:14:09
* @company: 睿展数据
* @FilePath: \salpa-web\config\proxy.ts
* @Descripttion:
*/
/**
* 在生产环境 代理是无法生效的,所以这里没有生产环境的配置
* -------------------------------
* The agent cannot take effect in the production environment
* so there is no configuration of the production environment
* For details, please see
* https://pro.ant.design/docs/deploy
*/
export default {
dev: {
'/api/': {
// target: 'http://192.168.103.172:8080',
target: 'http://192.168.1.217:9080',
changeOrigin: true,
pathRewrite: { '^/api': '' },
},
'/profile/avatar/': {
// target: 'http://192.168.103.172:8080',
target: 'http://192.168.113.251:8080',
changeOrigin: true,
},
},
test: {
'/api/': {
target: 'http://192.168.1.217:8080',
changeOrigin: true,
pathRewrite: { '^/api': '' },
},
},
pre: {
'/api/': {
target: 'your pre url',
changeOrigin: true,
pathRewrite: { '^': '' },
},
},
};