Files

9 lines
328 B
Bash
Raw Permalink Normal View History

2016-11-28 14:13:18 +01:00
#!/bin/bash
2026-04-08 01:17:05 +08:00
# $1 = exit code of the run script, $2 = signal
if [ "$1" -ne 0 ]; then
# avoid immediately restarting the sshd service, which may cause CPU 100% if the error (permission, configuration) is not fixed
echo "openssh failed with exit code $1 - waiting a short delay before attempting a restart"
sleep 3
fi
2016-11-28 14:13:18 +01:00
exit 0