jvb.conf 3.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798
  1. {{ $ENABLE_COLIBRI_WEBSOCKET := .Env.ENABLE_COLIBRI_WEBSOCKET | default "1" | toBool }}
  2. {{ $ENABLE_OCTO := .Env.ENABLE_OCTO | default "0" | toBool }}
  3. {{ $JVB_TCP_PORT := .Env.JVB_TCP_PORT | default "4443" }}
  4. {{ $JVB_TCP_MAPPED_PORT := .Env.JVB_TCP_MAPPED_PORT | default $JVB_TCP_PORT }}
  5. {{ $PUBLIC_URL_DOMAIN := .Env.PUBLIC_URL | default "https://localhost:8443" | trimPrefix "https://" | trimSuffix "/" -}}
  6. {{ $WS_DOMAIN := .Env.JVB_WS_DOMAIN | default $PUBLIC_URL_DOMAIN -}}
  7. {{ $WS_SERVER_ID := .Env.JVB_WS_SERVER_ID | default .Env.LOCAL_ADDRESS -}}
  8. {{ $COLIBRI_REST_ENABLED := .Env.COLIBRI_REST_ENABLED | default "false" | toBool }}
  9. {{ $SHUTDOWN_REST_ENABLED := .Env.SHUTDOWN_REST_ENABLED | default "false" | toBool }}
  10. videobridge {
  11. ice {
  12. udp {
  13. port = {{ .Env.JVB_PORT }}
  14. }
  15. tcp {
  16. enabled = {{ not (.Env.JVB_TCP_HARVESTER_DISABLED | default "true" | toBool) }}
  17. port = {{ .Env.JVB_TCP_PORT }}
  18. {{ if not (eq $JVB_TCP_PORT $JVB_TCP_MAPPED_PORT) }}
  19. mapped-port = {{ $JVB_TCP_MAPPED_PORT }}
  20. {{ end }}
  21. }
  22. }
  23. apis {
  24. xmpp-client {
  25. configs {
  26. shard {
  27. HOSTNAME = "{{ .Env.XMPP_SERVER }}"
  28. DOMAIN = "{{ .Env.XMPP_AUTH_DOMAIN }}"
  29. USERNAME = "{{ .Env.JVB_AUTH_USER }}"
  30. PASSWORD = "{{ .Env.JVB_AUTH_PASSWORD }}"
  31. MUC_JIDS = "{{ .Env.JVB_BREWERY_MUC }}@{{ .Env.XMPP_INTERNAL_MUC_DOMAIN }}"
  32. MUC_NICKNAME = "{{ .Env.HOSTNAME }}"
  33. DISABLE_CERTIFICATE_VERIFICATION = true
  34. }
  35. }
  36. }
  37. rest {
  38. enabled = {{ $COLIBRI_REST_ENABLED }}
  39. }
  40. }
  41. rest {
  42. shutdown {
  43. enabled = {{ $SHUTDOWN_REST_ENABLED }}
  44. }
  45. }
  46. stats {
  47. enabled = true
  48. }
  49. websockets {
  50. enabled = {{ $ENABLE_COLIBRI_WEBSOCKET }}
  51. domain = "{{ $WS_DOMAIN }}"
  52. tls = true
  53. server-id = "{{ $WS_SERVER_ID }}"
  54. }
  55. http-servers {
  56. private {
  57. host = 0.0.0.0
  58. }
  59. public {
  60. host = 0.0.0.0
  61. port = 9090
  62. }
  63. }
  64. {{ if $ENABLE_OCTO -}}
  65. octo {
  66. enabled = true
  67. bind-address = "{{ .Env.JVB_OCTO_BIND_ADDRESS | default "0.0.0.0" }}"
  68. public-address = "{{ .Env.JVB_OCTO_PUBLIC_ADDRESS }}"
  69. bind-port = "{{ .Env.JVB_OCTO_BIND_PORT | default "4096" }}"
  70. region = "{{ .Env.JVB_OCTO_REGION | default "europe" }}"
  71. }
  72. {{ end -}}
  73. }
  74. ice4j {
  75. harvest {
  76. mapping {
  77. stun {
  78. {{ if .Env.JVB_STUN_SERVERS -}}
  79. addresses = [ "{{ join "\",\"" (splitList "," .Env.JVB_STUN_SERVERS) }}" ]
  80. {{ else -}}
  81. enabled = false
  82. {{ end -}}
  83. }
  84. static-mappings = [
  85. {{ if .Env.DOCKER_HOST_ADDRESS -}}
  86. {
  87. local-address = "{{ .Env.LOCAL_ADDRESS }}"
  88. public-address = "{{ .Env.DOCKER_HOST_ADDRESS }}"
  89. }
  90. {{ end -}}
  91. ]
  92. }
  93. }
  94. }