diff --git a/root/etc/s6-overlay/s6-rc.d/cron/finish b/root/etc/s6-overlay/s6-rc.d/cron/finish index e6c6dd3..a6cb9ce 100644 --- a/root/etc/s6-overlay/s6-rc.d/cron/finish +++ b/root/etc/s6-overlay/s6-rc.d/cron/finish @@ -1,4 +1,9 @@ #!/command/with-contenv bash # shellcheck shell=bash -echo "$e" > /run/s6-linux-init-container-results/exitcode \ No newline at end of file +if [ $ONE_SHOT == "false" ]; then + + # Export exit code if not a ONE_SHOT + echo "$e" > /run/s6-linux-init-container-results/exitcode + +fi \ No newline at end of file diff --git a/root/etc/s6-overlay/s6-rc.d/logs/finish b/root/etc/s6-overlay/s6-rc.d/logs/finish index e6c6dd3..a6cb9ce 100644 --- a/root/etc/s6-overlay/s6-rc.d/logs/finish +++ b/root/etc/s6-overlay/s6-rc.d/logs/finish @@ -1,4 +1,9 @@ #!/command/with-contenv bash # shellcheck shell=bash -echo "$e" > /run/s6-linux-init-container-results/exitcode \ No newline at end of file +if [ $ONE_SHOT == "false" ]; then + + # Export exit code if not a ONE_SHOT + echo "$e" > /run/s6-linux-init-container-results/exitcode + +fi \ No newline at end of file