vue.config.js 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. module.exports = {
  2. lintOnSave: false,
  3. assetsDir: "static",
  4. publicPath: "/",
  5. outputDir: "dist",
  6. productionSourceMap: false,
  7. devServer: {
  8. port: 80,
  9. proxy: {
  10. [process.env.VUE_APP_BASE_API]: {
  11. // 本地环境
  12. // target: 'http://192.168.1.21:8080',
  13. // 服务器环境(测试)
  14. target: "https://xsmzctest.shizhi.tv/prod-api",
  15. // 服务器环境(生产)
  16. // target: 'https://smzc.shizhi.tv/prod-api',
  17. changeOrigin: true,
  18. pathRewrite: {
  19. ["^" + process.env.VUE_APP_BASE_API]: "",
  20. },
  21. },
  22. // 人脸识别
  23. "/oldRlsb": {
  24. target: "https://ai.sdaer.cn",
  25. pathRewrite: {
  26. "^/oldRlsb": "",
  27. },
  28. changeOrigin: true,
  29. },
  30. // kfWebVideo视频集成
  31. "/dispatch": {
  32. target: "https://kamfu.shaanxi.chinatax.gov.cn:8003/dispatch",
  33. changeOrigin: true,
  34. pathRewrite: {
  35. "^/dispatch": "/dispatch",
  36. },
  37. },
  38. "/aits": {
  39. target: "https://kamfu.shaanxi.chinatax.gov.cn:8003/aits",
  40. changeOrigin: true,
  41. pathRewrite: {
  42. "^/aits": "/aits",
  43. },
  44. },
  45. "/avd": {
  46. target: "https://spzxt.dg.cn:1443",
  47. pathRewrite: {
  48. "^/avd": "/",
  49. },
  50. changeorigin: true, //是否跨域fa
  51. secure: false, //是否使用https
  52. },
  53. },
  54. },
  55. };