module.exports = { css: { loaderOptions: { } }, configureWebpack: { performance: { hints: false }, devServer: { host: '0.0.0.0', port: 8002, contentBase: ['./node_modules', './public'], publicPath: '/', disableHostCheck: true, proxy: { '/api': { // target: `http://localhost:8080/`, // 本地开发环境 target: `http://218.59.175.43:92`, // 内网测试环境 // target: `http://116.255.223.226:8082/nsgk_test/`, // 公网测试环境 changeOrigin: true, onProxyReq: function (proxyReq, req) { console.log( '[HPM] Origin changed from ' + req.headers.host + ' ~> ' + proxyReq.getHeader('host') ); } }, '/geoserver': { target: 'http://localhost:37300', logLevel: 'debug', changeOrigin: true, onProxyReq: function (proxyReq, req) { console.log( '[HPM] Origin changed from ' + req.headers.host + ' ~> ' + proxyReq.getHeader('host') ); } } } } } };