config.local.js 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. 'use strict';
  2. /**
  3. * 开发环境配置,覆盖 config.default.js
  4. */
  5. module.exports = (appInfo) => {
  6. const config = {};
  7. /**
  8. * 开发者工具
  9. */
  10. config.openDevTools = {
  11. mode: "undocked",
  12. };
  13. /**
  14. * 应用程序顶部菜单
  15. */
  16. config.openAppMenu = true;
  17. /**
  18. * Cross-language service
  19. * 跨语言服务
  20. * 如果有cmd参数,则执行该命令且需要指定 directory
  21. */
  22. config.cross = {
  23. go: {
  24. // 应用运行时启动
  25. enable: false,
  26. // 程序名
  27. name: "goapp",
  28. // 可执行程序
  29. cmd: "go",
  30. // 程序目录
  31. directory: "./go",
  32. args: ["run", "./main.go", "--env=dev", "--basedir=../", "--port=7073"],
  33. appExit: true,
  34. },
  35. python: {
  36. enable: false,
  37. name: "pyapp",
  38. cmd: "python",
  39. directory: "./python",
  40. args: ["./main.py", "--port=7074"],
  41. stdio: "ignore",
  42. appExit: true,
  43. },
  44. };
  45. /**
  46. * jobs
  47. */
  48. config.jobs = {
  49. messageLog: true,
  50. };
  51. return {
  52. ...config,
  53. };
  54. };