|
|
@@ -28,6 +28,7 @@ module.exports = {
|
|
|
// transpileDependencies: true, // 默认情况下 babel-loader 忽略 node_modules 中的所有文件,启用此选项需配置transpileDependencies
|
|
|
transpileDependencies: [
|
|
|
/@aws-sdk/,
|
|
|
+ /@aws/,
|
|
|
/@smithy/,
|
|
|
/@huaweicloud/,
|
|
|
/vod-js-sdk-v6/
|
|
|
@@ -39,109 +40,7 @@ module.exports = {
|
|
|
open: true,
|
|
|
disableHostCheck: true,
|
|
|
proxy: {
|
|
|
- // 为 watch 模块单独设置的代理
|
|
|
- '/watch-api': {
|
|
|
- target: 'http://localhost:8004', // adminui watch服务
|
|
|
- changeOrigin: true,
|
|
|
- pathRewrite: {
|
|
|
- '^/watch-api': '' // 将 /watch-api 替换为空
|
|
|
- }
|
|
|
- },
|
|
|
- // 以下路径前缀代理到 fs-admin(8004) - 平台管理端
|
|
|
- // saasadminui前端API中这些路径只在fs-admin有Controller
|
|
|
- [process.env.VUE_APP_BASE_API + '/admin']: {
|
|
|
- target: 'http://localhost:8004',
|
|
|
- changeOrigin: true,
|
|
|
- pathRewrite: {
|
|
|
- ['^' + process.env.VUE_APP_BASE_API]: ''
|
|
|
- }
|
|
|
- },
|
|
|
- [process.env.VUE_APP_BASE_API + '/api']: {
|
|
|
- target: 'http://localhost:8004',
|
|
|
- changeOrigin: true,
|
|
|
- pathRewrite: {
|
|
|
- ['^' + process.env.VUE_APP_BASE_API]: ''
|
|
|
- }
|
|
|
- },
|
|
|
- [process.env.VUE_APP_BASE_API + '/baiduStatistics']: {
|
|
|
- target: 'http://localhost:8004',
|
|
|
- changeOrigin: true,
|
|
|
- pathRewrite: {
|
|
|
- ['^' + process.env.VUE_APP_BASE_API]: ''
|
|
|
- }
|
|
|
- },
|
|
|
- [process.env.VUE_APP_BASE_API + '/bd']: {
|
|
|
- target: 'http://localhost:8004',
|
|
|
- changeOrigin: true,
|
|
|
- pathRewrite: {
|
|
|
- ['^' + process.env.VUE_APP_BASE_API]: ''
|
|
|
- }
|
|
|
- },
|
|
|
- [process.env.VUE_APP_BASE_API + '/doctorChat']: {
|
|
|
- target: 'http://localhost:8004',
|
|
|
- changeOrigin: true,
|
|
|
- pathRewrite: {
|
|
|
- ['^' + process.env.VUE_APP_BASE_API]: ''
|
|
|
- }
|
|
|
- },
|
|
|
- [process.env.VUE_APP_BASE_API + '/easyCall']: {
|
|
|
- target: 'http://localhost:8004',
|
|
|
- changeOrigin: true,
|
|
|
- pathRewrite: {
|
|
|
- ['^' + process.env.VUE_APP_BASE_API]: ''
|
|
|
- }
|
|
|
- },
|
|
|
- [process.env.VUE_APP_BASE_API + '/hwcloud']: {
|
|
|
- target: 'http://localhost:8004',
|
|
|
- changeOrigin: true,
|
|
|
- pathRewrite: {
|
|
|
- ['^' + process.env.VUE_APP_BASE_API]: ''
|
|
|
- }
|
|
|
- },
|
|
|
- [process.env.VUE_APP_BASE_API + '/proxy']: {
|
|
|
- target: 'http://localhost:8004',
|
|
|
- changeOrigin: true,
|
|
|
- pathRewrite: {
|
|
|
- ['^' + process.env.VUE_APP_BASE_API]: ''
|
|
|
- }
|
|
|
- },
|
|
|
- [process.env.VUE_APP_BASE_API + '/sop']: {
|
|
|
- target: 'http://localhost:8004',
|
|
|
- changeOrigin: true,
|
|
|
- pathRewrite: {
|
|
|
- ['^' + process.env.VUE_APP_BASE_API]: ''
|
|
|
- }
|
|
|
- },
|
|
|
- [process.env.VUE_APP_BASE_API + '/statistic']: {
|
|
|
- target: 'http://localhost:8004',
|
|
|
- changeOrigin: true,
|
|
|
- pathRewrite: {
|
|
|
- ['^' + process.env.VUE_APP_BASE_API]: ''
|
|
|
- }
|
|
|
- },
|
|
|
- [process.env.VUE_APP_BASE_API + '/tenant']: {
|
|
|
- target: 'http://localhost:8004',
|
|
|
- changeOrigin: true,
|
|
|
- pathRewrite: {
|
|
|
- ['^' + process.env.VUE_APP_BASE_API]: ''
|
|
|
- }
|
|
|
- },
|
|
|
- [process.env.VUE_APP_BASE_API + '/third']: {
|
|
|
- target: 'http://localhost:8004',
|
|
|
- changeOrigin: true,
|
|
|
- pathRewrite: {
|
|
|
- ['^' + process.env.VUE_APP_BASE_API]: ''
|
|
|
- }
|
|
|
- },
|
|
|
- [process.env.VUE_APP_BASE_API + '/tool']: {
|
|
|
- target: 'http://localhost:8004',
|
|
|
- changeOrigin: true,
|
|
|
- pathRewrite: {
|
|
|
- ['^' + process.env.VUE_APP_BASE_API]: ''
|
|
|
- }
|
|
|
- },
|
|
|
- // detail: https://cli.vuejs.org/config/#devserver-proxy
|
|
|
- // 默认所有其他请求代理到 fs-company(8006) - 租户服务端
|
|
|
+ // adminminUi 是租户管理端,所有请求统一代理到 fs-company(8006)
|
|
|
[process.env.VUE_APP_BASE_API]: {
|
|
|
target: `http://localhost:8006`,
|
|
|
changeOrigin: true,
|
|
|
@@ -157,6 +56,27 @@ module.exports = {
|
|
|
alias: {
|
|
|
'@': resolve('src')
|
|
|
}
|
|
|
+ },
|
|
|
+ externals: {
|
|
|
+ 'node:async_hooks': 'commonjs async_hooks',
|
|
|
+ 'node:crypto': 'commonjs crypto',
|
|
|
+ 'node:fs': 'commonjs fs',
|
|
|
+ 'node:fs/promises': 'commonjs fs/promises',
|
|
|
+ 'node:http': 'commonjs http',
|
|
|
+ 'node:os': 'commonjs os',
|
|
|
+ 'node:path': 'commonjs path',
|
|
|
+ 'node:process': 'commonjs process',
|
|
|
+ 'node:stream': 'commonjs stream',
|
|
|
+ 'node:stream/web': 'commonjs stream',
|
|
|
+ 'node:buffer': 'commonjs buffer',
|
|
|
+ 'node:util': 'commonjs util',
|
|
|
+ 'node:url': 'commonjs url',
|
|
|
+ 'node:net': 'commonjs net',
|
|
|
+ 'node:tls': 'commonjs tls',
|
|
|
+ 'node:events': 'commonjs events',
|
|
|
+ 'node:https': 'commonjs https',
|
|
|
+ 'node:zlib': 'commonjs zlib',
|
|
|
+ 'node:child_process': 'commonjs child_process'
|
|
|
}
|
|
|
},
|
|
|
chainWebpack(config) {
|