Skip to content

Commit

Permalink
Merge pull request kubernetes#30816 from zmerlynn/aws-down-dangling-c…
Browse files Browse the repository at this point in the history
…onfig

Automatic merge from submit-queue

AWS: Handle kube-down case where the LaunchConfig is dangling

**What this PR does / why we need it**:

Fixed `cluster/kube-down.sh` on AWS in the case where no minions were started.

**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, #<issue_number>, ...)` format, will close that issue when PR gets merged)*: N/A

**Special notes for your reviewer**: N/A

**Release note**:

If we can't infer it from the tagged instances, assume we've created
the $ASG_NAME.
  • Loading branch information
Kubernetes Submit Queue authored Aug 17, 2016
2 parents 9ecee38 + ec33089 commit 332edf8
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions cluster/aws/util.sh
Original file line number Diff line number Diff line change
Expand Up @@ -1345,6 +1345,11 @@ function kube-down {
done
echo "All instances deleted"
fi
if [[ -n $(${AWS_ASG_CMD} describe-launch-configurations --launch-configuration-names ${ASG_NAME} --query LaunchConfigurations[].LaunchConfigurationName) ]]; then
echo "Warning: default auto-scaling launch configuration ${ASG_NAME} still exists, attempting to delete"
echo " (This may happen if kube-up leaves just the launch configuration but no auto-scaling group.)"
${AWS_ASG_CMD} delete-launch-configuration --launch-configuration-name ${ASG_NAME} || true
fi

find-master-pd
find-tagged-master-ip
Expand Down

0 comments on commit 332edf8

Please sign in to comment.