From fcef47b71206cda5859784f50121b9a2ffe88fac Mon Sep 17 00:00:00 2001 From: Asif Bacchus Date: Sun, 14 Oct 2018 10:22:35 -0600 Subject: [PATCH] Added ncMaint call in cleanup function --- backup.sh | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/backup.sh b/backup.sh index c2ebb02..7cbe3c0 100755 --- a/backup.sh +++ b/backup.sh @@ -114,6 +114,16 @@ function cleanup { echo -e "${op}${stamp} 503 error page never copied to webroot," \ "nothing to cleanup" >> "$logFile" fi + + ## Exit NextCloud maintenance mode regardless of current status + ncMaint off + # check if successful + if [ "$maintResult" = "0" ]; then + echo -e "${info}${stamp} -- [INFO] NextCloud now in regular" \ + "operating mode --${normal}" >> "$logFile" + else + quit 100 + fi } ### End of Functions ###