proxy.ts 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. /**
  2. * 在生产环境 代理是无法生效的,所以这里没有生产环境的配置
  3. * -------------------------------
  4. * The agent cannot take effect in the production environment
  5. * so there is no configuration of the production environment
  6. * For details, please see
  7. * https://pro.ant.design/docs/deploy
  8. */
  9. export default {
  10. dev: {
  11. '/api': {
  12. // target: 'http://192.168.32.28:8844/',
  13. // ws: 'ws://192.168.32.28:8844/',
  14. // 开发环境
  15. // target: 'http://120.79.18.123:8844/',
  16. // ws: 'ws://120.79.18.123:8844/',
  17. // 测试环境
  18. target: 'http://120.77.179.54:8844/',
  19. ws: 'ws://120.77.179.54:8844/',
  20. // target: 'http://192.168.32.86:8844/',
  21. // ws: 'ws://192.168.32.86:8844/',
  22. //v2环境
  23. // ws: 'ws://47.109.52.230:8844',
  24. // target: 'http://47.109.52.230:8844',
  25. changeOrigin: true,
  26. pathRewrite: { '^/api': '' },
  27. },
  28. },
  29. test: {
  30. '/api/': {
  31. target: 'https://preview.pro.ant.design',
  32. changeOrigin: true,
  33. pathRewrite: { '^': '' },
  34. },
  35. },
  36. pre: {
  37. '/api/': {
  38. target: 'your pre url',
  39. changeOrigin: true,
  40. pathRewrite: { '^': '' },
  41. },
  42. },
  43. };