From d133af4fed1501457ec6a129ac4604d7dab51eb0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gardais=20J=C3=A9r=C3=A9my?= Date: Thu, 18 Jun 2020 17:03:57 +0200 Subject: [PATCH] Exit with code 50 if upgrade fail --- cluster/apt.apply.update.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/cluster/apt.apply.update.sh b/cluster/apt.apply.update.sh index 9432d1e..42abaa0 100755 --- a/cluster/apt.apply.update.sh +++ b/cluster/apt.apply.update.sh @@ -256,7 +256,9 @@ main() { # {{{ && exit 0 ## Try to upgrade the system - upgrade_system + ### Exit 50 if any error in returned value + upgrade_system \ + || exit 50 ## If Maco upgrade is present ### Exit (and leave Maco manage required reboot if present)