aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--capsman-rolling-upgrade.capsman.rsc6
-rw-r--r--capsman-rolling-upgrade.template.rsc6
-rw-r--r--capsman-rolling-upgrade.wifi.rsc6
3 files changed, 15 insertions, 3 deletions
diff --git a/capsman-rolling-upgrade.capsman.rsc b/capsman-rolling-upgrade.capsman.rsc
index f287ea3..d0f9fb8 100644
--- a/capsman-rolling-upgrade.capsman.rsc
+++ b/capsman-rolling-upgrade.capsman.rsc
@@ -15,6 +15,7 @@
:global GlobalFunctionsReady;
:while ($GlobalFunctionsReady != true) do={ :delay 500ms; }
+:local ExitOK false;
:do {
:local ScriptName [ :jobname ];
@@ -22,6 +23,7 @@
:global ScriptLock;
:if ([ $ScriptLock $ScriptName ] = false) do={
+ :set ExitOK true;
:error false;
}
@@ -43,4 +45,6 @@
:delay ($Delay . "s");
}
}
-} on-error={ }
+} on-error={
+ :global ExitError; $ExitError $ExitOK [ :jobname ];
+}
diff --git a/capsman-rolling-upgrade.template.rsc b/capsman-rolling-upgrade.template.rsc
index 3d98747..1bd5f2a 100644
--- a/capsman-rolling-upgrade.template.rsc
+++ b/capsman-rolling-upgrade.template.rsc
@@ -16,6 +16,7 @@
:global GlobalFunctionsReady;
:while ($GlobalFunctionsReady != true) do={ :delay 500ms; }
+:local ExitOK false;
:do {
:local ScriptName [ :jobname ];
@@ -23,6 +24,7 @@
:global ScriptLock;
:if ([ $ScriptLock $ScriptName ] = false) do={
+ :set ExitOK true;
:error false;
}
@@ -51,4 +53,6 @@
:delay ($Delay . "s");
}
}
-} on-error={ }
+} on-error={
+ :global ExitError; $ExitError $ExitOK [ :jobname ];
+}
diff --git a/capsman-rolling-upgrade.wifi.rsc b/capsman-rolling-upgrade.wifi.rsc
index 369dccc..c9e6622 100644
--- a/capsman-rolling-upgrade.wifi.rsc
+++ b/capsman-rolling-upgrade.wifi.rsc
@@ -15,6 +15,7 @@
:global GlobalFunctionsReady;
:while ($GlobalFunctionsReady != true) do={ :delay 500ms; }
+:local ExitOK false;
:do {
:local ScriptName [ :jobname ];
@@ -22,6 +23,7 @@
:global ScriptLock;
:if ([ $ScriptLock $ScriptName ] = false) do={
+ :set ExitOK true;
:error false;
}
@@ -44,4 +46,6 @@
:delay ($Delay . "s");
}
}
-} on-error={ }
+} on-error={
+ :global ExitError; $ExitError $ExitOK [ :jobname ];
+}