From e48aac1c3066d9dd099b00d140f6548cfcbe4a0a Mon Sep 17 00:00:00 2001 From: Benoit Sautel Date: Sun, 27 Oct 2024 08:45:29 +0100 Subject: [PATCH] Add the ability to configure the application name. --- docker-compose.yml | 1 + web/rootfs/defaults/interface-config.js | 3 +++ web/rootfs/etc/cont-init.d/10-config | 1 + 3 files changed, 5 insertions(+) create mode 100644 web/rootfs/defaults/interface-config.js diff --git a/docker-compose.yml b/docker-compose.yml index bbc4e1e..5c3485f 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -19,6 +19,7 @@ services: - AMPLITUDE_ID - ANALYTICS_SCRIPT_URLS - ANALYTICS_WHITELISTED_EVENTS + - APP_NAME - AUDIO_QUALITY_OPUS_BITRATE - AUTO_CAPTION_ON_RECORD - BRANDING_DATA_URL diff --git a/web/rootfs/defaults/interface-config.js b/web/rootfs/defaults/interface-config.js new file mode 100644 index 0000000..c8499a5 --- /dev/null +++ b/web/rootfs/defaults/interface-config.js @@ -0,0 +1,3 @@ +{{ if .Env.APP_NAME -}} +interfaceConfig.APP_NAME = '{{ .Env.APP_NAME | js }}'; +{{ end -}} diff --git a/web/rootfs/etc/cont-init.d/10-config b/web/rootfs/etc/cont-init.d/10-config index be172ab..85991fd 100644 --- a/web/rootfs/etc/cont-init.d/10-config +++ b/web/rootfs/etc/cont-init.d/10-config @@ -126,6 +126,7 @@ if [[ -f /config/custom-config.js ]]; then fi cp /defaults/interface_config.js /config/interface_config.js +tpl /defaults/interface-config.js >> /config/interface_config.js if [[ -f /config/custom-interface_config.js ]]; then cat /config/custom-interface_config.js >> /config/interface_config.js fi