mirror of
https://github.com/nextcloud/all-in-one.git
synced 2025-12-19 22:16:49 +00:00
nextcloud - add turn_domain logic
Signed-off-by: Simon L <szaimen@e.mail.de>
This commit is contained in:
parent
dd20ffcf4e
commit
81c432a1a2
1 changed files with 5 additions and 2 deletions
|
|
@ -628,6 +628,9 @@ if [ "$TALK_ENABLED" = 'yes' ]; then
|
|||
TALK_HOST="$NC_DOMAIN"
|
||||
HPB_PATH="/standalone-signaling/"
|
||||
fi
|
||||
if [ -z "$TURN_DOMAIN" ]; then
|
||||
TURN_DOMAIN="$TALK_HOST"
|
||||
fi
|
||||
set +x
|
||||
if ! [ -d "/var/www/html/custom_apps/spreed" ]; then
|
||||
php /var/www/html/occ app:install spreed
|
||||
|
|
@ -639,11 +642,11 @@ if [ "$TALK_ENABLED" = 'yes' ]; then
|
|||
# Based on https://github.com/nextcloud/spreed/issues/960#issuecomment-416993435
|
||||
if [ -z "$(php /var/www/html/occ talk:turn:list --output="plain")" ]; then
|
||||
# shellcheck disable=SC2153
|
||||
php /var/www/html/occ talk:turn:add turn "$TALK_HOST:$TALK_PORT" "udp,tcp" --secret="$TURN_SECRET"
|
||||
php /var/www/html/occ talk:turn:add turn "$TURN_DOMAIN:$TALK_PORT" "udp,tcp" --secret="$TURN_SECRET"
|
||||
fi
|
||||
STUN_SERVER="$(php /var/www/html/occ talk:stun:list --output="plain")"
|
||||
if [ -z "$STUN_SERVER" ] || echo "$STUN_SERVER" | grep -oP '[a-zA-Z.:0-9]+' | grep -q "^stun.nextcloud.com:443$"; then
|
||||
php /var/www/html/occ talk:stun:add "$TALK_HOST:$TALK_PORT"
|
||||
php /var/www/html/occ talk:stun:add "$TURN_DOMAIN:$TALK_PORT"
|
||||
php /var/www/html/occ talk:stun:delete "stun.nextcloud.com:443"
|
||||
fi
|
||||
if ! php /var/www/html/occ talk:signaling:list --output="plain" | grep -q "https://$TALK_HOST$HPB_PATH"; then
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue