From 4f3300a93b1706958ccf154474e55ebdf2bef7f1 Mon Sep 17 00:00:00 2001 From: Valentin Lab Date: Fri, 10 May 2024 17:33:13 +0200 Subject: [PATCH] fix: [0km] repair invalid check for ``compose --debug up`` requirement Since the charm ``cron`` changed, this check require to be updated also. --- bin/0km | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/bin/0km b/bin/0km index d4a6bde..24709d4 100755 --- a/bin/0km +++ b/bin/0km @@ -953,16 +953,16 @@ vps_install_backup() { if [ "$type" == "compose" ]; then if ! ssh:run "root@$vps" -- \ docker exec myc_cron_1 \ - cat /etc/cron.d/rsync-backup >/dev/null 2>&1; then + grep rsync-backup /etc/crontabs/root >/dev/null 2>&1; then ssh:run "root@$vps" -- compose --debug up || { err "Command 'compose --debug up' failed." return 1 } if ! ssh:run "root@$vps" -- \ docker exec myc_cron_1 \ - cat /etc/cron.d/rsync-backup >/dev/null 2>&1; then + grep rsync-backup /etc/crontabs/root >/dev/null 2>&1; then err "Launched 'compose up' successfully but ${YELLOW}cron${NORMAL} container is not setup as expected." - echo " Was waiting for existence of '/etc/cron.d/rsync-backup' in it." >&2 + echo " Was waiting for existence of a line mentionning 'rsync-backup' in '/etc/crontabs/root' in it." >&2 return 1 fi fi