index.js 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. 'use strict'
  2. const path = require('path')
  3. module.exports = {
  4. //http://192.168.0.105:8081/
  5. //http://app.bluefire.top:8088 线上地址
  6. dev: {
  7. assetsSubDirectory: 'static',
  8. assetsPublicPath: '/',
  9. proxyTable: {
  10. '/': {
  11. // target: 'http://47.108.151.62:80/pre', //后端接口地址 中间人运营平台
  12. // target: 'http://47.108.151.62', //后端接口地址
  13. target: 'http://192.168.3.12:7001', //后端接口地址
  14. // target: 'http://127.0.0.1:28081', //后端接口地址
  15. // target: 'http://47.108.14.99:7001/', //后端接口地址
  16. changeOrigin: true, //是否跨域
  17. pathRewrite: {
  18. '^/': '/', //重写,
  19. }
  20. }
  21. },
  22. // 本地开发使用 192.168.0.126 localhost
  23. host: '192.168.3.4',
  24. // host: '192.168.124.14',
  25. port: 8081,
  26. autoOpenBrowser: true,
  27. errorOverlay: true,
  28. notifyOnErrors: false,
  29. poll: false,
  30. useEslint: true,
  31. showEslintErrorsInOverlay: false,
  32. devtool: 'cheap-source-map',
  33. cssSourceMap: false
  34. },
  35. build: {
  36. index: path.resolve(__dirname, '../dist/index.html'),
  37. assetsRoot: path.resolve(__dirname, '../dist'),
  38. assetsSubDirectory: 'static',
  39. assetsPublicPath: '/bid2/',
  40. productionSourceMap: false,
  41. devtool: 'source-map',
  42. productionGzip: false,
  43. productionGzipExtensions: ['js', 'css'],
  44. bundleAnalyzerReport: process.env.npm_config_report || false,
  45. generateAnalyzerReport: process.env.npm_config_generate_report || false
  46. }
  47. }