vue.config.js 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. module.exports = {
  2. publicPath: process.env.NODE_ENV === "production" ? "./" : "./", // 部署应用时的根路径(默认'/'),也可用相对路径(存在使用限制)
  3. outputDir: "cloudclinich5", // 运行时生成的生产环境构建文件的目录(默认''dist'',构建之前会被清除)
  4. assetsDir: "static", //放置生成的静态资源(s、css、img、fonts)的(相对于 outputDir 的)目录(默认'')
  5. lintOnSave: true, // 是否开启eslint保存检测
  6. productionSourceMap: false, // 是否在构建生产包时生成sourcdeMap
  7. devServer: {
  8. proxy: {
  9. // detail: https://cli.vuejs.org/config/#devserver-proxy
  10. [process.env.VUE_APP_BASE_API]: {
  11. // target: `http://192.168.1.10:8080/`, //王志飞本地
  12. // target: `http://cloudclinicapi.9czn.cn/`, // 测试地址
  13. // target: `http://115.236.184.102:8081/`, // 萧山物理机
  14. // target: 'http://192.168.204.124:8081/', // 客户正式服务器"
  15. // target: `http://121.43.162.141:80/`, // [萧山] 测试环境的后端地址
  16. // target: `https://wx.hzliuzhi.com:4433/fz/`, // [测试] 测试环境的后端
  17. // target: `https://tcm2.hzliuzhi.com/`, // @six 演示环境 2.0
  18. // target: `https://wx.hzliuzhi.com:4433/fz`, // @six kd演示环境
  19. target: `https://wx.hzliuzhi.com:4433/kd`,
  20. // target: `http://192.168.1.5:8091/`,
  21. // target: `https://tcm.hzliuzhi.com/`, // @six 演示环境
  22. // target: `http://www.hzxunmai.com/`, // 正式域名
  23. // target: `http://10.250.11.48:8080/`, // 正式域名
  24. changeOrigin: true,
  25. pathRewrite: {
  26. ['^' + process.env.VUE_APP_BASE_API]: ''
  27. }
  28. },
  29. '/file': {
  30. target: `http://121.43.162.141:80/`, // [萧山] 测试环境的后端地址
  31. }
  32. },
  33. }
  34. };