Kill all tasks on shutdown and startup

BindsTo will kill all the tasks when systemctl stop box is executed.
But when restarted, it keeps the tasks running. Because of this behavior,
we kill the tasks on startup and stop of the box code.
This commit is contained in:
Girish Ramakrishnan
2020-08-06 22:04:46 -07:00
parent 648d42dfe4
commit b1b6f70118
9 changed files with 43 additions and 31 deletions

View File

@@ -22,7 +22,9 @@ scripts=("${SOURCE_DIR}/src/scripts/clearvolume.sh" \
"${SOURCE_DIR}/src/scripts/collectlogs.sh" \
"${SOURCE_DIR}/src/scripts/configurecollectd.sh" \
"${SOURCE_DIR}/src/scripts/remotesupport.sh" \
"${SOURCE_DIR}/src/scripts/backupupload.js" \
"${SOURCE_DIR}/src/scripts/starttask.sh" \
"${SOURCE_DIR}/src/scripts/stoptask.sh" \
"${SOURCE_DIR}/src/scripts/rmmailbox.sh" \
"${SOURCE_DIR}/src/scripts/configurelogrotate.sh")
for script in "${scripts[@]}"; do