Skip to content

Commit

Permalink
Stop docker containers before cleaning up directories in case any of …
Browse files Browse the repository at this point in the history
…them were mounted
  • Loading branch information
cmmarslender committed Nov 4, 2024
1 parent 5b21801 commit 9239512
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions linux-runner/templates/post-run.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
#!/bin/bash

echo "Stopping any running docker containers"
docker stop $(docker ps -a -q) && docker rm $(docker ps -a -q)

shopt -s dotglob # Enable matching hidden files

directory="/home/{{ runner_user }}"
Expand Down Expand Up @@ -57,6 +60,3 @@ else
echo "All delete operations completed successfully."
exit 0
fi

echo "Stopping any running docker containers"
docker stop $(docker ps -a -q) && docker rm $(docker ps -a -q)

0 comments on commit 9239512

Please sign in to comment.