config.go 769 B

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. package main
  2. type GlobalConf struct {
  3. MongoB MgoConf
  4. Log Log
  5. Env EnvConf
  6. ES EsConf
  7. Email EmailConf
  8. }
  9. type EnvConf struct {
  10. FileStart string
  11. NomalStart string
  12. NextAddr string
  13. NextPort string
  14. LocalPort string
  15. Spec string
  16. SpecType string
  17. Send bool
  18. }
  19. type MgoConf struct {
  20. Host string
  21. DB string
  22. Coll string // 查询表
  23. Username string
  24. Password string
  25. Size int
  26. Direct bool
  27. }
  28. type Log struct {
  29. LogPath string
  30. MaxSize int
  31. Compress bool
  32. MaxAge int
  33. MaxBackups int
  34. LogLevel string
  35. Format string
  36. }
  37. type EsConf struct {
  38. URL string
  39. Username string
  40. Password string
  41. URL2 string
  42. Username2 string
  43. Password2 string
  44. }
  45. type EmailConf struct {
  46. Api string
  47. To string
  48. }