Skip to content

Commit 52e4377

Browse files
committed
wait for the docker container to stop before removing it
1 parent c56fc47 commit 52e4377

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

tools/build_test_env.sh

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,11 @@ CONFIG=/tmp/python-gitlab.cfg
5656
cleanup() {
5757
rm -f "${CONFIG}"
5858
log "Stopping gitlab-test docker container..."
59-
docker stop gitlab-test >/dev/null 2>&1
59+
docker stop gitlab-test >/dev/null 2>&1 &
60+
docker_stop_pid=$!
61+
log "Waiting for gitlab-test docker container to exit..."
62+
docker wait gitlab-test >/dev/null 2>&1
63+
wait "${docker_stop_pid}"
6064
log "Removing gitlab-test docker container..."
6165
docker rm gitlab-test >/dev/null 2>&1
6266
log "Deactivating Python virtualenv..."

0 commit comments

Comments
 (0)