You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

93 lines
2.1 KiB

  1. #! /bin/bash
  2. rm -f ./config.yaml
  3. # 生成config.yaml文件, 用于docker-compose的使用
  4. touch ./config.yaml
  5. filename="./config.yaml"
  6. cat>"${filename}"<<EOF
  7. # Gin-Vue-Admin Global Configuration
  8. # casbin configuration
  9. casbin:
  10. model-path: './resource/rbac_model.conf'
  11. # jwt configuration
  12. jwt:
  13. signing-key: 'qmPlus'
  14. # mysql connect configuration
  15. mysql:
  16. username: root
  17. password: 'Aa@6447985'
  18. path: mysql
  19. db-name: 'qmPlus'
  20. config: 'charset=utf8mb4&parseTime=True&loc=Local'
  21. max-idle-conns: 10
  22. max-open-conns: 10
  23. log-mode: true
  24. #sqlite 配置
  25. sqlite:
  26. path: db.db
  27. log-mode: true
  28. config: 'loc=Asia/Shanghai'
  29. # oss configuration
  30. # 切换本地与七牛云上传,分配头像和文件路径
  31. localupload:
  32. local: false
  33. avatar-path: uploads/avatar
  34. file-path: uploads/file
  35. # 请自行七牛申请对应的 公钥 私钥 bucket 和 域名地址
  36. qiniu:
  37. access-key: '25j8dYBZ2wuiy0yhwShytjZDTX662b8xiFguwxzZ'
  38. secret-key: 'pgdbqEsf7ooZh7W3xokP833h3dZ_VecFXPDeG5JY'
  39. bucket: 'qm-plus-img'
  40. img-path: 'http://qmplusimg.henrongyi.top'
  41. # redis configuration
  42. redis:
  43. addr: redis:6379
  44. password: ''
  45. db: 0
  46. # system configuration
  47. system:
  48. use-multipoint: true
  49. env: 'public' # Change to "develop" to skip authentication for development mode
  50. addr: 8888
  51. db-type: "mysql" # support mysql/sqlite
  52. # captcha configuration
  53. captcha:
  54. key-long: 6
  55. img-width: 240
  56. img-height: 80
  57. # zap logger configuration
  58. zap:
  59. # 可使用 "debug", "info", "warn", "error", "dpanic", "panic", "fatal",
  60. level: 'info'
  61. # console: 控制台, json: json格式输出
  62. format: 'console'
  63. prefix: '[GIN-VUE-ADMIN]'
  64. director: 'log'
  65. link-name: 'latest_log'
  66. show-line: true
  67. # LowercaseLevelEncoder:小写, LowercaseColorLevelEncoder:小写带颜色,CapitalLevelEncoder: 大写, CapitalColorLevelEncoder: 大写带颜色,
  68. encode-level: 'LowercaseColorLevelEncoder'
  69. stacktrace-key: 'stacktrace'
  70. log-in-console: true
  71. email:
  72. email-from: 'xxx@163.com'
  73. email-nickname: 'test'
  74. email-secret: 'xxx'
  75. email-to: 'xxx@qq.com'
  76. email-host: 'smtp.163.com'
  77. email-port: 465
  78. email-isSSL: true
  79. EOF