From 0a8ca779ef8fe788f4b00a0172d3c71712f83e1f Mon Sep 17 00:00:00 2001 From: "Alex A. Naanou" Date: Mon, 8 Jan 2024 02:26:47 +0300 Subject: [PATCH] testing... Signed-off-by: Alex A. Naanou --- .pct-helpers | 22 +++++++++++++--------- nextcloud/make.sh | 6 ++++-- 2 files changed, 17 insertions(+), 11 deletions(-) diff --git a/.pct-helpers b/.pct-helpers index 43e6ec5..894a3c1 100644 --- a/.pct-helpers +++ b/.pct-helpers @@ -210,16 +210,20 @@ xreadpass(){ # tklWaitForSetup(){ printf "$1" - while ! $(lxc-attach $ID -- test -e /etc/inithooks.conf) ; do - printf '.' + if [ -z $DRY_RUN ] ; then + while ! $(lxc-attach $ID -- test -e /etc/inithooks.conf) ; do + printf '.' + sleep 5 + done + printf '+' sleep 5 - done - printf '+' - sleep 5 - while ! [[ $(lxc-attach $ID -- cat /etc/inithooks.conf | wc -c) < 2 ]] ; do - printf '.' - sleep 5 - done + while ! [[ $(lxc-attach $ID -- cat /etc/inithooks.conf | wc -c) < 2 ]] ; do + printf '.' + sleep 5 + done + else + printf '.+..' + fi printf 'ready.\n' sleep 5 } diff --git a/nextcloud/make.sh b/nextcloud/make.sh index a22bb47..97f5264 100755 --- a/nextcloud/make.sh +++ b/nextcloud/make.sh @@ -93,14 +93,16 @@ sleep ${TIMEOUT:=5} tklWaitForSetup "# TKL setup, this may take a while" +@ pct reboot $ID + echo "# Starting TKL UI..." -#@ lxc-attach $ID -- bash --login -c 'exit' +@ lxc-attach $ID -- /usr/sbin/trunkey-init + exit # XXX the CT will reboot -- wait... -##@ lxc-attach $ID -- /usr/sbin/trunkey-init # #echo "# Updating config..." ## XXX update /var/www/nextcloud/config/config.php