Created
June 15, 2019 20:26
-
-
Save gavinzhou/994979827b5e9270af9843d4b2725b56 to your computer and use it in GitHub Desktop.
delete-gke-nog
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
BAD_INSTANCE=[your node name from kubectl get nodes] | |
kubectl cordon $BAD_INSTANCE | |
kubectl drain $BAD_INSTANCE | |
gcloud compute instances describe --format='value[](metadata.items.created-by)' $BAD_INSTANCE | |
gcloud compute instance-groups managed delete-instances --instances=$BAD_INSTANCE --zone=[from describe output] [grp from describe output] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment