From 1633a976a426f4e9a8a05aa58e59349f8809b086 Mon Sep 17 00:00:00 2001 From: Matt Winter Date: Fri, 16 Apr 2021 12:36:09 -0400 Subject: [PATCH] Only remove the cron.d file if it exists Signed-off-by: Matt Winter --- s6/debian-root/etc/cont-init.d/20-start.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/s6/debian-root/etc/cont-init.d/20-start.sh b/s6/debian-root/etc/cont-init.d/20-start.sh index cc1627c..907e403 100644 --- a/s6/debian-root/etc/cont-init.d/20-start.sh +++ b/s6/debian-root/etc/cont-init.d/20-start.sh @@ -18,7 +18,7 @@ if [ -z "$SKIPGRAVITYONBOOT" ]; then echo '@reboot root PATH="$PATH:/usr/sbin:/usr/local/bin/" pihole updateGravity >/var/log/pihole_updateGravity.log || cat /var/log/pihole_updateGravity.log' > /etc/cron.d/gravity-on-boot else echo " Skipping Gravity Database Update." - rm /etc/cron.d/gravity-on-boot &>/dev/null + [ ! -e /etc/cron.d/gravity-on-boot ] || rm /etc/cron.d/gravity-on-boot &>/dev/null fi # Kill dnsmasq because s6 won't like it if it's running when s6 services start