config.yaml 2.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. lang: "zh-CN"
  2. app:
  3. web-client: 1 # 1:启用 0:禁用
  4. register: false #是否开启注册
  5. register-status: 1 # 注册用户默认状态 1:启用 2:禁用
  6. captcha-threshold: 3 # <0:disabled, 0 always, >0:enabled
  7. ban-threshold: 0 # 0:disabled, >0:enabled
  8. show-swagger: 0 # 1:启用 0:禁用
  9. token-expire: 168h
  10. web-sso: true #web auth sso
  11. disable-pwd-login: false #禁用密码登录
  12. admin:
  13. title: "RustDesk Api Admin"
  14. hello-file: "./conf/admin/hello.html" #优先使用file
  15. hello: ""
  16. # ID Server and Relay Server ports https://github.com/lejianwen/rustdesk-api/issues/257
  17. id-server-port: 21116 # ID Server port (for server cmd)
  18. relay-server-port: 21117 # ID Server port (for server cmd)
  19. gin:
  20. api-addr: "0.0.0.0:21114"
  21. mode: "release" #release,debug,test
  22. resources-path: 'resources' #对外静态文件目录
  23. trust-proxy: ""
  24. gorm:
  25. type: "sqlite"
  26. max-idle-conns: 10
  27. max-open-conns: 100
  28. mysql:
  29. username: ""
  30. password: ""
  31. addr: ""
  32. dbname: ""
  33. rustdesk:
  34. id-server: "192.168.1.66:21116"
  35. relay-server: "192.168.1.66:21117"
  36. api-server: "http://127.0.0.1:21114"
  37. key: ""
  38. key-file: "/data/id_ed25519.pub"
  39. personal: 1
  40. webclient-magic-queryonline: 0
  41. ws-host: "" #eg: wss://192.168.1.3:4443
  42. logger:
  43. path: "./runtime/log.txt"
  44. level: "info" #trace,debug,info,warn,error,fatal
  45. report-caller: true
  46. proxy:
  47. enable: false
  48. host: "http://127.0.0.1:1080"
  49. jwt:
  50. key: ""
  51. expire-duration: 168h
  52. ldap:
  53. enable: false
  54. url: "ldap://ldap.example.com:389"
  55. tls-ca-file: ""
  56. tls-verify: false
  57. base-dn: "dc=example,dc=com"
  58. bind-dn: "cn=admin,dc=example,dc=com"
  59. bind-password: "password"
  60. user:
  61. base-dn: "ou=users,dc=example,dc=com"
  62. enable-attr: "" #The attribute name of the user for enabling, in AD it is "userAccountControl", empty means no enable attribute, all users are enabled
  63. enable-attr-value: "" # The value of the enable attribute when the user is enabled. If you are using AD, just set random value, it will be ignored.
  64. filter: "(cn=*)"
  65. username: "uid" # The attribute name of the user for usernamem if you are using AD, it should be "sAMAccountName"
  66. email: "mail"
  67. first-name: "givenName"
  68. last-name: "sn"
  69. sync: false # If true, the user will be synchronized to the database when the user logs in. If false, the user will be synchronized to the database when the user be created.
  70. admin-group: "cn=admin,dc=example,dc=com" # The group name of the admin group, if the user is in this group, the user will be an admin.