mirror of
https://github.com/cp2k/cp2k.git
synced 2026-07-29 06:35:28 -04:00
Docker: Prevent crash looping
This commit is contained in:
parent
dd6be25fbc
commit
402e0699ef
1 changed files with 2 additions and 2 deletions
|
|
@ -40,7 +40,7 @@ function upload_final_report {
|
|||
function error_handler {
|
||||
echo -e "\nSummary: Something went wrong.\nStatus: FAILED" | tee -a $REPORT
|
||||
upload_final_report
|
||||
exit 1
|
||||
exit 0 # prevent crash looping
|
||||
}
|
||||
trap error_handler ERR
|
||||
|
||||
|
|
@ -48,7 +48,7 @@ trap error_handler ERR
|
|||
function sigterm_handler {
|
||||
echo -e "\nThis job just got preempted. No worries, it should restart soon." | tee -a $REPORT
|
||||
upload_final_report
|
||||
exit 2
|
||||
exit 1 # trigger retry
|
||||
}
|
||||
trap sigterm_handler SIGTERM
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue