summaryrefslogtreecommitdiffstats
path: root/remove-images.sh
diff options
context:
space:
mode:
authorIkram Ikramullah <ikram@research.att.com>2018-03-14 11:37:06 -0400
committerIkram Ikramullah <ikram@research.att.com>2018-03-14 12:51:19 -0400
commitebdfcf84d04682152a366b220a5650bba03bfb75 (patch)
treea3fd44a147a0541d9001f27eaf9173c4bd496941 /remove-images.sh
parente4cee54e5b2bf43b3da857866036b1d178ee9617 (diff)
Docker dir - removed unused conf file
Removed file not needed for docker images. (conductor.conf). Also, added a remove-images.sh to remove images if needed. Issue-ID: OPTFRA-123 Change-Id: I7494a47da268a229d3d6730eb23fd5a5deb27653 Signed-off-by: Ikram Ikramullah <ikram@research.att.com>
Diffstat (limited to 'remove-images.sh')
-rwxr-xr-xremove-images.sh20
1 files changed, 20 insertions, 0 deletions
diff --git a/remove-images.sh b/remove-images.sh
new file mode 100755
index 0000000..66abe3f
--- /dev/null
+++ b/remove-images.sh
@@ -0,0 +1,20 @@
+echo "Removing data containers and images !!!"
+docker rm $(docker ps -a -q --filter ancestor=data)
+docker rmi -f $(docker images -a | grep "data" | awk '{print $3}')
+
+echo "Removing controller containers and images !!!"
+docker rm $(docker ps -a -q --filter ancestor=controller)
+docker rmi -f $(docker images -a | grep "controller" | awk '{print $3}')
+
+echo "Removing api containers and images !!!"
+docker rm $(docker ps -a -q --filter ancestor=api)
+docker rmi -f $(docker images -a | grep "api" | awk '{print $3}')
+
+echo "Removing solver containers and images !!!"
+docker rm $(docker ps -a -q --filter ancestor=solver)
+docker rmi -f $(docker images -a | grep "solver" | awk '{print $3}')
+
+echo "Removing reservation containers and images !!!"
+docker rm $(docker ps -a -q --filter ancestor=reservation)
+docker rmi -f $(docker images -a | grep "reservation" | awk '{print $3}')
+