dev.conf 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104
  1. [base]
  2. [setting]
  3. ;以下几个配置都是云平台生成
  4. ;农场名称
  5. name = 新农宝盒本地服务
  6. ;农场id
  7. farm = 1
  8. ;农场站点
  9. site = http://www.xinnongbaohe.com/
  10. copyright = 2017 xingnongbaohe.com v1.0.0
  11. [db]
  12. rdb = postgresql
  13. tsdb = influxdb
  14. [postgresql]
  15. host = 0.0.0.0
  16. port = 5432
  17. username = postgres
  18. password = 123456
  19. dbname = xinnongbaohe
  20. prefix = demeter
  21. ;允许自动建表
  22. create = True
  23. [influxdb]
  24. host = 0.0.0.0
  25. port = 8086
  26. username = root
  27. password = root
  28. dbname = xinnongbaohe
  29. prefix = demeter
  30. [redis]
  31. host = 0.0.0.0
  32. password = dm_redis_123
  33. port = 6379
  34. name = eros
  35. prefix = eros_
  36. [modbus]
  37. host = 192.168.33.10
  38. port = 1152
  39. [mqtt]
  40. host = 0.0.0.0
  41. port = 1883
  42. username = admin
  43. password = public
  44. timeout = 60
  45. ;topic定义
  46. topic = method/type/gateway/device
  47. sub = pic,sensor,power,status,log|control
  48. ;后台配置
  49. [admin]
  50. port = 8090
  51. debug = True
  52. ;请求的buffersize
  53. max_buffer_size = 210763776
  54. ;子进程
  55. process = 0
  56. ;定义后台父级菜单
  57. menu_parent = 农场管理:,设备管理:,配置管理:
  58. ;定义后台子级菜单
  59. menu_child = 基础资料:/farm/info?id=1,用户管理:/farm/user,产品管理:/farm/product,地块管理:/work/land,农事管理:/work/work;网关列表:/device/gateway,设备列表:/device/info;产品配置:/setting/product,服务配置:/setting/server,设备类型:/setting/device_type,硬件类型:/hardware/type,MODBUS命令码:/setting/modbus_code,错误码配置:/device/notice_type,消息类型设置:/msg/type
  60. ;cookie
  61. cookie_secret = 61oETzKXQAGaYekL5gEmGeJJFuYh7EQnp2XdTP1o/Vo=
  62. login_url = /user/login
  63. ;是否使用安全cookie
  64. xsrf_cookies = True
  65. ;前台配置
  66. [front]
  67. port = 8091
  68. debug = True
  69. max_buffer_size = 210763776
  70. process = 0
  71. url = http://192.168.33.10:8091/device
  72. qrcode = http://pan.baidu.com/share/qrcode?w=300&h=300&url=
  73. mobile = True
  74. ;网站前台配置
  75. [web]
  76. port = 8092
  77. debug = True
  78. max_buffer_size = 210763776
  79. process = 0
  80. url = http://www.xinnongbaohe.com/
  81. farmurl = http://farm.xinnongbaohe.com/?id=
  82. originurl = http://s.xinnongbaohe.com/?id=
  83. ;云端配置
  84. [zeus]
  85. host = http://192.168.33.10:8088/
  86. ;同步配置
  87. [sync]
  88. ;同步的表,多个用逗号隔开
  89. table = farm,farm_user,farm_product,farm_work,farm_work_method,farm_work_category,farm_work_land,origin_batch,origin_growth,device_info,device_gateway,device_camera,device_camera_pic,device_group,device_page,device_pic,device_printer,device_set_condition,device_set_loop,device_set_timing
  90. ;同步的方法,仅限service
  91. service = core,zeus