From 6474e890bbd3438bedda6c1c837bfd1b00d40671 Mon Sep 17 00:00:00 2001 From: Rob Ballantyne Date: Fri, 22 Mar 2024 20:35:38 +0000 Subject: [PATCH] Add support for service URL --- build/COPY_ROOT/opt/ai-dock/bin/supervisor-kasmvnc.sh | 3 ++- .../opt/ai-dock/bin/supervisor-selkies-gstreamer.sh | 11 ++++++----- docker-compose.yaml | 5 +++++ 3 files changed, 13 insertions(+), 6 deletions(-) diff --git a/build/COPY_ROOT/opt/ai-dock/bin/supervisor-kasmvnc.sh b/build/COPY_ROOT/opt/ai-dock/bin/supervisor-kasmvnc.sh index c855edd..df9ce13 100755 --- a/build/COPY_ROOT/opt/ai-dock/bin/supervisor-kasmvnc.sh +++ b/build/COPY_ROOT/opt/ai-dock/bin/supervisor-kasmvnc.sh @@ -5,7 +5,7 @@ trap cleanup EXIT LISTEN_PORT=${VNC_PORT_LOCAL:-16200} METRICS_PORT=${VNC_METRICS_PORT:-26200} PROXY_PORT=${VNC_PORT_HOST:-6200} -PROXY_SECURE=true +SERVICE_URL="${VNC_URL:-}" QUICKTUNNELS=true SERVICE_NAME="KDE Plasma Desktop (VNC Fallback)" @@ -30,6 +30,7 @@ function start() { --arg proxy_port "${PROXY_PORT}" \ --arg proxy_secure "${PROXY_SECURE,,}" \ --arg service_name "${SERVICE_NAME}" \ + --arg service_url "${SERVICE_URL}" \ '$ARGS.named' )" diff --git a/build/COPY_ROOT/opt/ai-dock/bin/supervisor-selkies-gstreamer.sh b/build/COPY_ROOT/opt/ai-dock/bin/supervisor-selkies-gstreamer.sh index 345ebc0..6205784 100755 --- a/build/COPY_ROOT/opt/ai-dock/bin/supervisor-selkies-gstreamer.sh +++ b/build/COPY_ROOT/opt/ai-dock/bin/supervisor-selkies-gstreamer.sh @@ -2,10 +2,10 @@ trap cleanup EXIT -LISTEN_PORT=${SELKIES_PORT_LOCAL:-16100} -METRICS_PORT=${SELKIES_METRICS_PORT:-26100} -PROXY_PORT=${SELKIES_PORT_HOST:-6100} -PROXY_SECURE=true +LISTEN_PORT=${WEBRTC_PORT_LOCAL:-16100} +METRICS_PORT=${WEBRTC_METRICS_PORT:-26100} +PROXY_PORT=${WEBRTC_PORT_HOST:-6100} +SERVICE_URL="${WEBRTC_URL:-}" QUICKTUNNELS=true SERVICE_NAME="KDE Plasma Desktop (WebRTC)" @@ -31,6 +31,7 @@ function start() { --arg proxy_port "${PROXY_PORT}" \ --arg proxy_secure "${PROXY_SECURE,,}" \ --arg service_name "${SERVICE_NAME}" \ + --arg service_url "${SERVICE_URL}" \ '$ARGS.named' )" @@ -94,7 +95,7 @@ function start() { --enable_basic_auth=false \ --addr="127.0.0.1" \ --port="${LISTEN_PORT}" \ - --metrics_port=26105 $SELKIES_FLAGS + --metrics_port=26105 $WEBRTC_FLAGS } start 2>&1 \ No newline at end of file diff --git a/docker-compose.yaml b/docker-compose.yaml index 74a57ab..aff36f8 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -68,6 +68,7 @@ services: - TURN_PASSWORD=${TURN_PASSWORD:-} - WEBRTC_ENABLE_RESIZE=${WEBRTC_ENABLE_RESIZE:-false} - WEBRTC_ENCODER=${WEBRTC_ENCODER:-nvh264enc} + - WEBRTC_FLAGS=${WEBRTC_FLAGS:-} - DIRECT_ADDRESS=${DIRECT_ADDRESS:-127.0.0.1} - DIRECT_ADDRESS_GET_WAN=${DIRECT_ADDRESS_GET_WAN:-false} - WORKSPACE=${WORKSPACE:-/workspace} @@ -81,13 +82,17 @@ services: - SSH_PORT_LOCAL=${SSH_PORT_LOCAL:-22} - SERVICEPORTAL_PORT_HOST=${SERVICEPORTAL_PORT_HOST:-1111} - SERVICEPORTAL_METRICS_PORT=${SERVICEPORTAL_METRICS_PORT:-21111} + - SERVICEPORTAL_URL=${SERVICEPORTAL_URL:-} - VNC_PORT_HOST=${VNC_PORT_HOST:-6200} - VNC_METRICS_PORT=${VNC_METRICS_PORT:-26200} + - VNC_URL=${VNC_URL:-} - WEBRTC_PORT_HOST=${WEBRTC_PORT_HOST:-6100} - WEBRTC_METRICS_PORT=${WEBRTC_METRICS_PORT:-26100} + - WEBRTC_URL=${WEBRTC_URL:-} - SERVERLESS=${SERVERLESS:-false} - SYNCTHING_UI_PORT_HOST=${SYNCTHING_UI_PORT_HOST:-8384} - SYNCTHING_TRANSPORT_PORT_HOST=${SYNCTHING_TRANSPORT_PORT_HOST:-22999} + - SYNCTHING_URL=${SYNCTHING_URL:-} #- PROVISIONING_SCRIPT=${PROVISIONING_SCRIPT:-} # Magic bullet to solve networking issues - I don't like it