biiig wrench
This commit is contained in:
@ -1,13 +1,17 @@
|
||||
#!/bin/bash
|
||||
source "$(dirname "$0")/_common.sh"
|
||||
source "${AGENT_PATH}/_common.sh"
|
||||
|
||||
# Required environment variables
|
||||
check_required_env_vars "CONTAINER_NAME" "IMAGE_REGISTRY" "IMAGE_REPO" "IMAGE_TAG"
|
||||
# Watchtower Uninstall Script
|
||||
|
||||
_remove_container $CONTAINER_NAME || die "Failed to remove container ${CONTAINER_NAME}"
|
||||
|
||||
# remove the image
|
||||
docker rmi "$IMAGE_REGISTRY/$IMAGE_REPO:$IMAGE_TAG" || echo "Failed to remove image $IMAGE_REGISTRY/$IMAGE_REPO:$IMAGE_TAG"
|
||||
# Load service environment variables
|
||||
source ./service.env
|
||||
_check_required_env_vars "CONTAINER_NAME" "IMAGE_REGISTRY" "IMAGE_REPO" "IMAGE_TAG"
|
||||
|
||||
echo "Uninstallation of ${CONTAINER_NAME} complete."
|
||||
echo "Uninstalling service ${CONTAINER_NAME}..."
|
||||
_remove_container $CONTAINER_NAME || _die "Failed to remove container ${CONTAINER_NAME}"
|
||||
|
||||
echo "Service ${CONTAINER_NAME} uninstalled."
|
||||
|
||||
# Note: Watchtower doesn't typically have volumes to nuke.
|
||||
|
||||
|
Reference in New Issue
Block a user