Skip to content

Commit e67a31c

Browse files
committed
fix: replace static paths by env variables
Signed-off-by: Hendrik Leidinger <hendrik.leidinger@nextcloud.com>
1 parent 41de46b commit e67a31c

1 file changed

Lines changed: 5 additions & 5 deletions

File tree

build/scripts/standalone/entrypoint.sh

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ DATA_DIR="/var/www/euro-office/Data"
1111
PRIVATE_DIR="${DATA_DIR}/.private"
1212
CONFIG_FILE="${EO_CONF}/local.json"
1313
LOG4JS_CONFIG="${EO_CONF}/log4js/production.json"
14-
EXAMPLE_CONF_DIR="/etc/euro-office/documentserver-example"
14+
EXAMPLE_CONF_DIR="${EO_CONF}-example"
1515
EXAMPLE_LOCAL="${EXAMPLE_CONF_DIR}/local.json"
1616
NGINX_CONFIG_PATH="/etc/nginx/nginx.conf"
1717
NGINX_DS_DIR="${EO_CONF}/nginx"
@@ -378,8 +378,8 @@ fi
378378
# Welcome page rewrite (preserved from previous entrypoint).
379379
# --------------------------------------------------------------------
380380
update_welcome_page() {
381-
WELCOME_PAGE="/var/www/euro-office/documentserver-example/welcome/docker.html"
382-
EXAMPLE_DISABLED_PAGE="/var/www/euro-office/documentserver-example/welcome/example-disabled.html"
381+
WELCOME_PAGE="${EO_ROOT}-example/welcome/docker.html"
382+
EXAMPLE_DISABLED_PAGE="${EO_ROOT}-example/welcome/example-disabled.html"
383383

384384
[ -f "$EXAMPLE_DISABLED_PAGE" ] && \
385385
sed -i 's|sudo systemctl start ds-example|sudo docker exec $(sudo docker ps -q) supervisorctl start ds:example|g' \
@@ -405,8 +405,8 @@ update_welcome_page() {
405405
}
406406
update_welcome_page
407407

408-
# Symlink /config -> /etc/euro-office/documentserver for tools that expect it
409-
ln -sf /etc/euro-office/documentserver /config 2>/dev/null || true
408+
# Symlink /config -> ${EO_CONF} for tools that expect it
409+
ln -sf ${EO_CONF} /config 2>/dev/null || true
410410

411411
# Ensure api.js template (required by documentserver-flush-cache.sh)
412412
API_TPL="${EO_ROOT}/web-apps/apps/api/documents/api.js.tpl"

0 commit comments

Comments
 (0)