tsg-web/src/setupProxy.js

28 lines
702 B
JavaScript
Raw Normal View History

2024-09-20 15:02:50 +08:00
const { createProxyMiddleware } = require('http-proxy-middleware');
module.exports = function (app) {
//咸丰调度系统
app.use(
'/gunshiApp',
createProxyMiddleware({
2024-11-14 15:19:12 +08:00
target: 'http://local.gunshiiot.com:18083/',//测试
2024-09-26 17:45:57 +08:00
// target: 'http://192.168.66.199:24105/',//正式
2024-09-20 15:02:50 +08:00
// target: 'http://36.139.207.50:18083/',//移动云
2024-11-14 15:19:12 +08:00
// target: 'http://192.168.66.49:24105/',//移动云
2024-09-20 15:02:50 +08:00
changeOrigin: true,
})
);
//卫星云图,雷达回波需要
app.use(
'/shzh/service2',
createProxyMiddleware({
target: 'http://223.75.53.141:8000/',
changeOrigin: true,
pathRewrite: {
'^/shzh/service2': '',
},
})
);
};