2
0

10-config 1.2 KB

123456789101112131415161718192021222324252627282930313233
  1. #!/usr/bin/with-contenv bash
  2. if [[ -z $JVB_AUTH_PASSWORD ]]; then
  3. echo 'FATAL ERROR: JVB auth password must be set'
  4. exit 1
  5. fi
  6. OLD_JVB_AUTH_PASSWORD=passw0rd
  7. if [[ "$JVB_AUTH_PASSWORD" == "$OLD_JVB_AUTH_PASSWORD" ]]; then
  8. echo 'FATAL ERROR: JVB auth password must be changed, check the README'
  9. exit 1
  10. fi
  11. [ -z "${XMPP_SERVER}" ] && export XMPP_SERVER=xmpp.meet.jitsi
  12. # On environments like Swarm the IP address used by the default gateway need not be
  13. # the one used for inter-container traffic. Use that one for our fallback ID.
  14. XMPP_SERVER_IP=$(dig +short +search ${XMPP_SERVER})
  15. export JVB_WS_SERVER_ID_FALLBACK=$(ip route get ${XMPP_SERVER_IP} | grep -oP '(?<=src ).*' | awk '{ print $1 '})
  16. # Local IP for the ice4j mapping harvester.
  17. export LOCAL_ADDRESS=$(ip route get 1 | grep -oP '(?<=src ).*' | awk '{ print $1 '})
  18. export SENTRY_RELEASE="${SENTRY_RELEASE:-$(apt-cache policy jitsi-videobridge2 | sed -n '/Installed/p' | sed -e 's/[^:]*: //')}"
  19. if [[ -f /config/custom-sip-communicator.properties ]]; then
  20. cat /config/custom-sip-communicator.properties > /config/sip-communicator.properties
  21. fi
  22. tpl /defaults/logging.properties > /config/logging.properties
  23. tpl /defaults/jvb.conf > /config/jvb.conf
  24. chown -R jvb:jitsi /config