ejabberd-example.yml 5.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240
  1. ###
  2. ### ejabberd configuration file
  3. ###
  4. ### The parameters used in this configuration file are explained at
  5. ###
  6. ### https://docs.ejabberd.im/admin/configuration
  7. ###
  8. ### The configuration file is written in YAML.
  9. ### *******************************************************
  10. ### ******* !!! WARNING !!! *******
  11. ### ******* YAML IS INDENTATION SENSITIVE *******
  12. ### ******* MAKE SURE YOU INDENT SECTIONS CORRECTLY *******
  13. ### *******************************************************
  14. ### Refer to http://en.wikipedia.org/wiki/YAML for the brief description.
  15. ###
  16. hosts:
  17. - localhost
  18. loglevel: info
  19. ## If you already have certificates, list them here
  20. # certfiles:
  21. # - /etc/letsencrypt/live/domain.tld/fullchain.pem
  22. # - /etc/letsencrypt/live/domain.tld/privkey.pem
  23. listen:
  24. -
  25. port: 5222
  26. ip: "::"
  27. module: ejabberd_c2s
  28. max_stanza_size: 262144
  29. shaper: c2s_shaper
  30. access: c2s
  31. starttls_required: true
  32. -
  33. port: 5223
  34. ip: "::"
  35. tls: true
  36. module: ejabberd_c2s
  37. max_stanza_size: 262144
  38. shaper: c2s_shaper
  39. access: c2s
  40. starttls_required: true
  41. -
  42. port: 5269
  43. ip: "::"
  44. module: ejabberd_s2s_in
  45. max_stanza_size: 524288
  46. -
  47. port: 5443
  48. ip: "::"
  49. module: ejabberd_http
  50. tls: true
  51. request_handlers:
  52. /admin: ejabberd_web_admin
  53. /api: mod_http_api
  54. /bosh: mod_bosh
  55. /captcha: ejabberd_captcha
  56. /upload: mod_http_upload
  57. /ws: ejabberd_http_ws
  58. -
  59. port: 5280
  60. ip: "::"
  61. module: ejabberd_http
  62. request_handlers:
  63. /admin: ejabberd_web_admin
  64. /.well-known/acme-challenge: ejabberd_acme
  65. -
  66. port: 3478
  67. ip: "::"
  68. transport: udp
  69. module: ejabberd_stun
  70. use_turn: true
  71. ## The server's public IPv4 address:
  72. # turn_ipv4_address: "203.0.113.3"
  73. ## The server's public IPv6 address:
  74. # turn_ipv6_address: "2001:db8::3"
  75. -
  76. port: 1883
  77. ip: "::"
  78. module: mod_mqtt
  79. backlog: 1000
  80. s2s_use_starttls: optional
  81. acl:
  82. local:
  83. user_regexp: ""
  84. loopback:
  85. ip:
  86. - 127.0.0.0/8
  87. - ::1/128
  88. access_rules:
  89. local:
  90. allow: local
  91. c2s:
  92. deny: blocked
  93. allow: all
  94. announce:
  95. allow: admin
  96. configure:
  97. allow: admin
  98. muc_create:
  99. allow: local
  100. pubsub_createnode:
  101. allow: local
  102. trusted_network:
  103. allow: loopback
  104. api_permissions:
  105. "console commands":
  106. from:
  107. - ejabberd_ctl
  108. who: all
  109. what: "*"
  110. "admin access":
  111. who:
  112. access:
  113. allow:
  114. - acl: loopback
  115. - acl: admin
  116. oauth:
  117. scope: "ejabberd:admin"
  118. access:
  119. allow:
  120. - acl: loopback
  121. - acl: admin
  122. what:
  123. - "*"
  124. - "!stop"
  125. - "!start"
  126. "public commands":
  127. who:
  128. ip: 127.0.0.1/8
  129. what:
  130. - status
  131. - connected_users_number
  132. shaper:
  133. normal:
  134. rate: 3000
  135. burst_size: 20000
  136. fast: 100000
  137. shaper_rules:
  138. max_user_sessions: 10
  139. max_user_offline_messages:
  140. 5000: admin
  141. 100: all
  142. c2s_shaper:
  143. none: admin
  144. normal: all
  145. s2s_shaper: fast
  146. modules:
  147. mod_adhoc: {}
  148. mod_admin_extra: {}
  149. mod_announce:
  150. access: announce
  151. mod_avatar: {}
  152. mod_blocking: {}
  153. mod_bosh: {}
  154. mod_caps: {}
  155. mod_carboncopy: {}
  156. mod_client_state: {}
  157. mod_configure: {}
  158. mod_disco: {}
  159. mod_fail2ban: {}
  160. mod_http_api: {}
  161. mod_http_upload:
  162. put_url: https://@HOST@:5443/upload
  163. custom_headers:
  164. "Access-Control-Allow-Origin": "https://@HOST@"
  165. "Access-Control-Allow-Methods": "GET,HEAD,PUT,OPTIONS"
  166. "Access-Control-Allow-Headers": "Content-Type"
  167. mod_last: {}
  168. mod_mam:
  169. ## Mnesia is limited to 2GB, better to use an SQL backend
  170. ## For small servers SQLite is a good fit and is very easy
  171. ## to configure. Uncomment this when you have SQL configured:
  172. ## db_type: sql
  173. assume_mam_usage: true
  174. default: always
  175. mod_mqtt: {}
  176. mod_muc:
  177. access:
  178. - allow
  179. access_admin:
  180. - allow: admin
  181. access_create: muc_create
  182. access_persistent: muc_create
  183. access_mam:
  184. - allow
  185. default_room_options:
  186. mam: true
  187. mod_muc_admin: {}
  188. mod_offline:
  189. access_max_user_messages: max_user_offline_messages
  190. mod_ping: {}
  191. mod_privacy: {}
  192. mod_private: {}
  193. mod_proxy65:
  194. access: local
  195. max_connections: 5
  196. mod_pubsub:
  197. access_createnode: pubsub_createnode
  198. plugins:
  199. - flat
  200. - pep
  201. force_node_config:
  202. ## Avoid buggy clients to make their bookmarks public
  203. storage:bookmarks:
  204. access_model: whitelist
  205. mod_push: {}
  206. mod_push_keepalive: {}
  207. mod_register:
  208. ## Only accept registration requests from the "trusted"
  209. ## network (see access_rules section above).
  210. ## Think twice before enabling registration from any
  211. ## address. See the Jabber SPAM Manifesto for details:
  212. ## https://github.com/ge0rg/jabber-spam-fighting-manifesto
  213. ip_access: trusted_network
  214. mod_roster:
  215. versioning: true
  216. mod_s2s_dialback: {}
  217. mod_shared_roster: {}
  218. mod_stream_mgmt:
  219. resend_on_timeout: if_offline
  220. mod_stun_disco: {}
  221. mod_vcard: {}
  222. mod_vcard_xupdate: {}
  223. mod_version:
  224. show_os: false
  225. ### Local Variables:
  226. ### mode: yaml
  227. ### End:
  228. ### vim: set filetype=yaml tabstop=8