Enforce removal of container network namespace.
This patch enforces the removal of the container network namespace when the environment is destroyed. Closes-Bug: #1769651 Change-Id: I9b0bbbb5a59e6067a745635c555051ef97b79f9a Signed-off-by: Jorge Niedbalski <jorge.niedbalski@linaro.org>
This commit is contained in:
parent
d67a2d288d
commit
6c5a6c65f1
@ -35,6 +35,11 @@ echo "Stopping containers..."
|
||||
echo "Removing containers..."
|
||||
(docker rm -v -f ${containers_to_kill} 2>&1) > /dev/null
|
||||
|
||||
echo "Disconnecting containers from docker host network"
|
||||
for container in ${containers_to_kill}; do
|
||||
(docker network disconnect -f host $container 2>&1) > /dev/null
|
||||
done
|
||||
|
||||
echo "Removing volumes..."
|
||||
(docker volume rm ${volumes_to_remove} 2>&1) > /dev/null
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user