summaryrefslogtreecommitdiffstats
path: root/examples/docker/remove_hc2vpp_containers.sh
diff options
context:
space:
mode:
Diffstat (limited to 'examples/docker/remove_hc2vpp_containers.sh')
-rwxr-xr-xexamples/docker/remove_hc2vpp_containers.sh11
1 files changed, 11 insertions, 0 deletions
diff --git a/examples/docker/remove_hc2vpp_containers.sh b/examples/docker/remove_hc2vpp_containers.sh
new file mode 100755
index 000000000..c1fbf705a
--- /dev/null
+++ b/examples/docker/remove_hc2vpp_containers.sh
@@ -0,0 +1,11 @@
+#!/bin/bash
+
+ids=$(docker ps -aq --filter ancestor=hc2vpp)
+
+# Stop all hc2vpp based containers
+echo "Stopping containers: $ids"
+docker stop $ids
+
+# Delete all hc2vpp based containers
+echo "Removing containers: $ids"
+docker rm $ids