Sai Gandham | 67a6d89 | 2018-10-10 04:31:59 -0500 | [diff] [blame] | 1 | #!/bin/bash |
| 2 | # Pull in Variables from d.props |
| 3 | . ./d.props |
| 4 | DOCKER=${DOCKER:=docker} |
| 5 | |
| 6 | if [ "$1" == "" ]; then |
| 7 | AAF_COMPONENTS="$(cat components) config core agent" |
| 8 | else |
| 9 | AAF_COMPONENTS="$@" |
| 10 | fi |
| 11 | |
| 12 | echo "Y" | $DOCKER container prune |
| 13 | for AAF_COMPONENT in ${AAF_COMPONENTS}; do |
| 14 | $DOCKER image rm $ORG/$PROJECT/aaf_$AAF_COMPONENT:${VERSION} |
| 15 | if [ ! "$PREFIX" = "" ]; then |
| 16 | $DOCKER image rm $DOCKER_REPOSITORY/$ORG/$PROJECT/aaf_$AAF_COMPONENT:${VERSION} |
| 17 | $DOCKER image rm $DOCKER_REPOSITORY/$ORG/$PROJECT/aaf_$AAF_COMPONENT:latest |
| 18 | fi |
| 19 | done |
| 20 | echo "Y" | $DOCKER image prune |