|
|
|
@ -1,5 +1,6 @@ |
|
|
|
|
#!/usr/bin/with-contenv bash |
|
|
|
|
|
|
|
|
|
if [[ -z $JVB_DISABLE_XMPP ]]; then |
|
|
|
|
if [[ -z $JVB_AUTH_PASSWORD ]]; then |
|
|
|
|
echo 'FATAL ERROR: JVB auth password must be set' |
|
|
|
|
exit 1 |
|
|
|
@ -13,6 +14,12 @@ fi |
|
|
|
|
|
|
|
|
|
[ -z "${XMPP_SERVER}" ] && export XMPP_SERVER=xmpp.meet.jitsi |
|
|
|
|
|
|
|
|
|
# On environments like Swarm the IP address used by the default gateway need not be |
|
|
|
|
# the one used for inter-container traffic. Use that one for our fallback ID. |
|
|
|
|
XMPP_SERVER_IP=$(dig +short +search ${XMPP_SERVER}) |
|
|
|
|
export JVB_WS_SERVER_ID_FALLBACK=$(ip route get ${XMPP_SERVER_IP} | grep -oP '(?<=src ).*' | awk '{ print $1 '}) |
|
|
|
|
fi |
|
|
|
|
|
|
|
|
|
# Migration from DOCKER_HOST_ADDRESS to JVB_ADVERTISE_IPS |
|
|
|
|
if [[ -z "${JVB_ADVERTISE_IPS}" ]]; then |
|
|
|
|
if [[ ! -z "${DOCKER_HOST_ADDRESS}" ]]; then |
|
|
|
@ -21,11 +28,6 @@ if [[ -z "${JVB_ADVERTISE_IPS}" ]]; then |
|
|
|
|
fi |
|
|
|
|
fi |
|
|
|
|
|
|
|
|
|
# On environments like Swarm the IP address used by the default gateway need not be |
|
|
|
|
# the one used for inter-container traffic. Use that one for our fallback ID. |
|
|
|
|
XMPP_SERVER_IP=$(dig +short +search ${XMPP_SERVER}) |
|
|
|
|
export JVB_WS_SERVER_ID_FALLBACK=$(ip route get ${XMPP_SERVER_IP} | grep -oP '(?<=src ).*' | awk '{ print $1 '}) |
|
|
|
|
|
|
|
|
|
# Local IP for the ice4j mapping harvester. |
|
|
|
|
export LOCAL_ADDRESS=$(ip route get 1 | grep -oP '(?<=src ).*' | awk '{ print $1 '}) |
|
|
|
|
|
|
|
|
|