2
0

jitsi-meet.cfg.lua 5.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156
  1. admins = {
  2. "{{ .Env.JICOFO_AUTH_USER }}@{{ .Env.XMPP_AUTH_DOMAIN }}",
  3. "{{ .Env.JVB_AUTH_USER }}@{{ .Env.XMPP_AUTH_DOMAIN }}"
  4. }
  5. plugin_paths = { "/prosody-plugins/", "/prosody-plugins-custom" }
  6. http_default_host = "{{ .Env.XMPP_DOMAIN }}"
  7. {{ $ENABLE_AUTH := .Env.ENABLE_AUTH | default "0" | toBool }}
  8. {{ $ENABLE_GUEST_DOMAIN := and $ENABLE_AUTH (.Env.ENABLE_GUESTS | default "0" | toBool)}}
  9. {{ $AUTH_TYPE := .Env.AUTH_TYPE | default "internal" }}
  10. {{ $JWT_ASAP_KEYSERVER := .Env.JWT_ASAP_KEYSERVER | default "" }}
  11. {{ $JWT_ALLOW_EMPTY := .Env.JWT_ALLOW_EMPTY | default "0" | toBool }}
  12. {{ $JWT_AUTH_TYPE := .Env.JWT_AUTH_TYPE | default "token" }}
  13. {{ $JWT_TOKEN_AUTH_MODULE := .Env.JWT_TOKEN_AUTH_MODULE | default "token_verification" }}
  14. {{ $ENABLE_LOBBY := .Env.ENABLE_LOBBY | default "0" | toBool }}
  15. {{ if and $ENABLE_AUTH (eq $AUTH_TYPE "jwt") .Env.JWT_ACCEPTED_ISSUERS }}
  16. asap_accepted_issuers = { "{{ join "\",\"" (splitList "," .Env.JWT_ACCEPTED_ISSUERS) }}" }
  17. {{ end }}
  18. {{ if and $ENABLE_AUTH (eq $AUTH_TYPE "jwt") .Env.JWT_ACCEPTED_AUDIENCES }}
  19. asap_accepted_audiences = { "{{ join "\",\"" (splitList "," .Env.JWT_ACCEPTED_AUDIENCES) }}" }
  20. {{ end }}
  21. VirtualHost "{{ .Env.XMPP_DOMAIN }}"
  22. {{ if $ENABLE_AUTH }}
  23. {{ if eq $AUTH_TYPE "jwt" }}
  24. authentication = "{{ $JWT_AUTH_TYPE }}"
  25. app_id = "{{ .Env.JWT_APP_ID }}"
  26. app_secret = "{{ .Env.JWT_APP_SECRET }}"
  27. allow_empty_token = {{ if $JWT_ALLOW_EMPTY }}true{{ else }}false{{ end }}
  28. {{ if $JWT_ASAP_KEYSERVER }}
  29. asap_key_server = "{{ .Env.JWT_ASAP_KEYSERVER }}"
  30. {{ end }}
  31. {{ else if eq $AUTH_TYPE "ldap" }}
  32. authentication = "cyrus"
  33. cyrus_application_name = "xmpp"
  34. allow_unencrypted_plain_auth = true
  35. {{ else if eq $AUTH_TYPE "internal" }}
  36. authentication = "internal_hashed"
  37. {{ end }}
  38. {{ else }}
  39. authentication = "anonymous"
  40. {{ end }}
  41. ssl = {
  42. key = "/config/certs/{{ .Env.XMPP_DOMAIN }}.key";
  43. certificate = "/config/certs/{{ .Env.XMPP_DOMAIN }}.crt";
  44. }
  45. modules_enabled = {
  46. "bosh";
  47. "pubsub";
  48. "ping";
  49. "speakerstats";
  50. "conference_duration";
  51. {{ if and $ENABLE_LOBBY (not $ENABLE_GUEST_DOMAIN) }}
  52. "muc_lobby_rooms";
  53. {{ end }}
  54. {{ if .Env.XMPP_MODULES }}
  55. "{{ join "\";\n\"" (splitList "," .Env.XMPP_MODULES) }}";
  56. {{ end }}
  57. {{ if and $ENABLE_AUTH (eq $AUTH_TYPE "ldap") }}
  58. "auth_cyrus";
  59. {{end}}
  60. }
  61. {{ if and $ENABLE_LOBBY (not $ENABLE_GUEST_DOMAIN) }}
  62. main_muc = "{{ .Env.XMPP_MUC_DOMAIN }}"
  63. lobby_muc = "lobby.{{ .Env.XMPP_DOMAIN }}"
  64. {{ if .Env.XMPP_RECORDER_DOMAIN }}
  65. muc_lobby_whitelist = { "{{ .Env.XMPP_RECORDER_DOMAIN }}" }
  66. {{ end }}
  67. {{ end }}
  68. speakerstats_component = "speakerstats.{{ .Env.XMPP_DOMAIN }}"
  69. conference_duration_component = "conferenceduration.{{ .Env.XMPP_DOMAIN }}"
  70. c2s_require_encryption = false
  71. {{ if $ENABLE_GUEST_DOMAIN }}
  72. VirtualHost "{{ .Env.XMPP_GUEST_DOMAIN }}"
  73. authentication = "anonymous"
  74. c2s_require_encryption = false
  75. {{ if $ENABLE_LOBBY }}
  76. modules_enabled = {
  77. "muc_lobby_rooms";
  78. }
  79. main_muc = "{{ .Env.XMPP_MUC_DOMAIN }}"
  80. lobby_muc = "lobby.{{ .Env.XMPP_DOMAIN }}"
  81. {{ if .Env.XMPP_RECORDER_DOMAIN }}
  82. muc_lobby_whitelist = { "{{ .Env.XMPP_RECORDER_DOMAIN }}" }
  83. {{ end }}
  84. {{ end }}
  85. {{ end }}
  86. VirtualHost "{{ .Env.XMPP_AUTH_DOMAIN }}"
  87. ssl = {
  88. key = "/config/certs/{{ .Env.XMPP_AUTH_DOMAIN }}.key";
  89. certificate = "/config/certs/{{ .Env.XMPP_AUTH_DOMAIN }}.crt";
  90. }
  91. authentication = "internal_hashed"
  92. {{ if .Env.XMPP_RECORDER_DOMAIN }}
  93. VirtualHost "{{ .Env.XMPP_RECORDER_DOMAIN }}"
  94. modules_enabled = {
  95. "ping";
  96. }
  97. authentication = "internal_hashed"
  98. {{ end }}
  99. Component "{{ .Env.XMPP_INTERNAL_MUC_DOMAIN }}" "muc"
  100. storage = "memory"
  101. modules_enabled = {
  102. "ping";
  103. {{ if .Env.XMPP_INTERNAL_MUC_MODULES }}
  104. "{{ join "\";\n\"" (splitList "," .Env.XMPP_INTERNAL_MUC_MODULES) }}";
  105. {{ end }}
  106. }
  107. muc_room_locking = false
  108. muc_room_default_public_jids = true
  109. Component "{{ .Env.XMPP_MUC_DOMAIN }}" "muc"
  110. storage = "memory"
  111. modules_enabled = {
  112. "muc_meeting_id";
  113. {{ if .Env.XMPP_MUC_MODULES }}
  114. "{{ join "\";\n\"" (splitList "," .Env.XMPP_MUC_MODULES) }}";
  115. {{ end }}
  116. {{ if and $ENABLE_AUTH (eq $AUTH_TYPE "jwt") }}
  117. "{{ $JWT_TOKEN_AUTH_MODULE }}";
  118. {{ end }}
  119. }
  120. muc_room_cache_size = 1000
  121. muc_room_locking = false
  122. muc_room_default_public_jids = true
  123. Component "focus.{{ .Env.XMPP_DOMAIN }}"
  124. component_secret = "{{ .Env.JICOFO_COMPONENT_SECRET }}"
  125. Component "speakerstats.{{ .Env.XMPP_DOMAIN }}" "speakerstats_component"
  126. muc_component = "{{ .Env.XMPP_MUC_DOMAIN }}"
  127. Component "conferenceduration.{{ .Env.XMPP_DOMAIN }}" "conference_duration_component"
  128. muc_component = "{{ .Env.XMPP_MUC_DOMAIN }}"
  129. {{ if $ENABLE_LOBBY }}
  130. Component "lobby.{{ .Env.XMPP_DOMAIN }}" "muc"
  131. storage = "memory"
  132. restrict_room_creation = true
  133. muc_room_locking = false
  134. muc_room_default_public_jids = true
  135. {{ end }}