Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AWS kube-down: Issue warning if VPC not found #27518

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
10 changes: 10 additions & 0 deletions cluster/aws/util.sh
Original file line number Diff line number Diff line change
Expand Up @@ -1501,6 +1501,16 @@ function kube-down {

echo "Deleting VPC: ${vpc_id}"
$AWS_CMD delete-vpc --vpc-id $vpc_id > $LOG
else
echo "" >&2
echo -e "${color_red}Cluster NOT deleted!${color_norm}" >&2
echo "" >&2
echo "No VPC was found with tag KubernetesCluster=${CLUSTER_ID}" >&2
echo "" >&2
echo "If you are trying to delete a cluster in a shared VPC," >&2
echo "please consider using one of the methods in the kube-deploy repo." >&2
echo "See: https://github.com/kubernetes/kube-deploy/blob/master/docs/delete_cluster.md" >&2
exit 1
fi
}

Expand Down