File tree Expand file tree Collapse file tree 1 file changed +8
-1
lines changed
Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -93,7 +93,14 @@ cleanup () {
9393
9494 if ghe-ssh " $GHE_HOSTNAME " -- ' ghe-config --true app.actions.enabled' ; then
9595 echo " Restarting Actions after restore ..."
96- ghe-ssh " $GHE_HOSTNAME " -- ' ghe-actions-start' 1>&3
96+ # In GHES 3.3+, ghe-actions-start no longer has a -f (force) flag. In GHES 3.2 and below, we must provide the
97+ # force flag to make sure it can start in maintenance mode. Use it conditionally based on whether it exists
98+ # in the --help output
99+ if ghe-ssh " $GHE_HOSTNAME " -- ' ghe-actions-start --help' | grep -q force ; then
100+ ghe-ssh " $GHE_HOSTNAME " -- ' ghe-actions-start -f' 1>&3
101+ else
102+ ghe-ssh " $GHE_HOSTNAME " -- ' ghe-actions-start' 1>&3
103+ fi
97104 fi
98105
99106 # Cleanup SSH multiplexing
You can’t perform that action at this time.
0 commit comments