delete.sh 439 Bytes
  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
#!/bin/bash
# Stop containers and removes containers, networks, volumes, and images
docker-compose -f docker-compose-jfrog.yml down

# Wait a bit
sleep 5s

# Check that containers were removed succesfully
res=`docker ps -a | grep "/curex-local/kea_" | wc -l`
if [ $res -eq 0 ]; then
echo "All KEA docker containers have been stopped and removed."
else
echo "ERROR: Some KEA containers have not been removed."
docker ps -a
exit 1
fi