diff --git a/nextcloud/make.sh b/nextcloud/make.sh index 916ac4d..b031af2 100755 --- a/nextcloud/make.sh +++ b/nextcloud/make.sh @@ -70,6 +70,9 @@ sleep ${TIMEOUT:=5} tklWaitForSetup +# XXX this breaks the rest of this script... +echo "# Starting TKL UI..." +@ lxc-attach $ID -- bash -c "HUB_APIKEY=SKIP SEC_UPDATES=SKIP /usr/sbin/turnkey-init" echo "# Updating config..." # add gate IP to trusted_proxies... @@ -78,7 +81,7 @@ echo "# Updating config..." -e \"/trusted_domains/i\\ 'trusted_proxies' =>\\n array (\\n '${GATE_LAN_IP/\/*}\\/32',\\n ),\" \ /var/www/nextcloud/config/config.php" # add self IP to trusted_domains -- enable setup from local network... -IP=${DRY_RUN:=$(lxc-attach $ID -- hostname -I)} +IP=$([ -z $DRY_RUN ] && lxc-attach $ID -- hostname -I) @ lxc-attach $ID -- bash -c "\ sed -z -i \ -e \"s/\\(trusted_domains[^)]*\\)/\\1 2 => '${IP/ *}',\\n /\" \ @@ -100,17 +103,9 @@ echo "# Post config..." pctSet $ID "${OPTS_STAGE_2}" $REBOOT -# XXX this breaks the rest of this script... -echo "# Starting TKL UI..." -#@ lxc-attach $ID -- bash -c 'HUB_APIKEY=SKIP SEC_UPDATES=SKIP /usr/sbin/turnkey-init' -@ lxc-attach $ID -- bash -c 'HUB_APIKEY=SKIP /usr/sbin/turnkey-init' - - echo "# Done." #---------------------------------------------------------------------- # vim:set ts=4 sw=4 : - -