diff --git a/facts/general/system.yml b/facts/general/system.yml index a617226..6778338 100644 --- a/facts/general/system.yml +++ b/facts/general/system.yml @@ -15,6 +15,17 @@ runit_log_dir: log global_log: /var/log global_log_config: config + runit_finish_sleep: | + #!/bin/sh + exec 2>&1 + # $1 is the exit code, $2 is the exit status byte (signal number if killed) + echo "FINISH: Service returned with exit code: $1 and status: $2" + + sleep=30 + if [[ "$1" != 0 ]]; then + echo "FINISH: Sleeping for $sleep seconds due to error..." + sleep $sleep + fi - name: General | Facts | System | Global 02 ansible.builtin.set_fact: