mirror of
https://github.com/OpenNebula/one.git
synced 2025-03-21 14:50:08 +03:00
parent
673e651639
commit
8942bcf659
@ -49,14 +49,19 @@ CONTEXT_PATH="$SHARE_LOCATION/context"
|
||||
DOCKERFILES="$SHARE_LOCATION/dockerhub/dockerfiles"
|
||||
DOCKERFILE="$SHARE_LOCATION/dockerhub"
|
||||
|
||||
#Docker image name for deletion
|
||||
image_name=$(echo "$MARKET_URL" | cut -d "/" -f3 | cut -d "?" -f1)
|
||||
|
||||
#-------------------------------------------------------------------------------
|
||||
# This function takes care of removing all temporary directories in case
|
||||
# something fails
|
||||
#-------------------------------------------------------------------------------
|
||||
function clean {
|
||||
docker rm -f "$container_id" > /dev/null 2>&1 || true
|
||||
docker rmi $(docker images -q) -f
|
||||
docker rmi -f $image_name
|
||||
docker image rm -f one"$sid" > /dev/null 2>&1
|
||||
|
||||
|
||||
rm -rf "$dockerdir"
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user