|
@@ -27,38 +27,34 @@ module.exports = {
|
|
|
productionSourceMap: false,
|
|
|
|
|
|
// webpack-dev-server 相关配置
|
|
|
- devServer: {
|
|
|
- host: '0.0.0.0',
|
|
|
- port: port,
|
|
|
- open: true,
|
|
|
- proxy: {
|
|
|
- // detail: https://cli.vuejs.org/config/#devserver-proxy
|
|
|
- [process.env.VUE_APP_BASE_API]: {
|
|
|
- // target: `http://172.16.120.213:8084/`, //本地
|
|
|
- // target: `http://172.16.120.85:8084/`, //本地
|
|
|
- // target: 'http://172.16.120.49/dmapi/', //49
|
|
|
- target: 'https://smartpark.caih.com/dmapi/', //东信
|
|
|
- changeOrigin: true,
|
|
|
- pathRewrite: {
|
|
|
- ['^' + process.env.VUE_APP_BASE_API]: ''
|
|
|
- }
|
|
|
- },
|
|
|
- '/YtIoT': {
|
|
|
- // target: 'http://47.103.74.123:8080/YtIoT', //这里填入你要请求的接口的前缀
|
|
|
- target: 'https://smartpark.caih.com/YtIoT', //这里填入你要请求的接口的前缀
|
|
|
- wss: true, //代理websocked
|
|
|
- changeOrigin: true, //虚拟的站点需要更换origin
|
|
|
- secure: true, //是否https接口,我用的http但是我变成false他打包后会报错,所以先true
|
|
|
- pathRewrite: {
|
|
|
- '^/api': '' //重写路径
|
|
|
- }
|
|
|
+ // devServer: {
|
|
|
+ // host: '0.0.0.0',
|
|
|
+ // port: port,
|
|
|
+ // open: true,
|
|
|
+ // proxy: {
|
|
|
+ // // detail: https://cli.vuejs.org/config/#devserver-proxy
|
|
|
+ // [process.env.VUE_APP_BASE_API]: {
|
|
|
+ // target: '',
|
|
|
+ // changeOrigin: true,
|
|
|
+ // pathRewrite: {
|
|
|
+ // ['^' + process.env.VUE_APP_BASE_API]: ''
|
|
|
+ // }
|
|
|
+ // },
|
|
|
+ // '/YtIoT': {
|
|
|
+ // target: '', //这里填入你要请求的接口的前缀
|
|
|
+ // wss: true, //代理websocked
|
|
|
+ // changeOrigin: true, //虚拟的站点需要更换origin
|
|
|
+ // secure: true, //是否https接口,我用的http但是我变成false他打包后会报错,所以先true
|
|
|
+ // pathRewrite: {
|
|
|
+ // '^/api': '' //重写路径
|
|
|
+ // }
|
|
|
|
|
|
- }
|
|
|
+ // }
|
|
|
|
|
|
|
|
|
- },
|
|
|
- disableHostCheck: true
|
|
|
- },
|
|
|
+ // },
|
|
|
+ // disableHostCheck: true
|
|
|
+ // },
|
|
|
configureWebpack: {
|
|
|
name: name,
|
|
|
resolve: {
|