How to shutdown a kops Kubernetes cluster on AWS

While playing with the excellent lops I had the need to shutdown the cluster while not in use, this proved hard as every time I stopped the machines, something would turn it back on, turns out it was the AWS autoscaling groups.

To fix this I didn’t wanted to mess with the kops settings on the AWS side so I had to find the kops way to do this.

What I ended up doing was changing the instance groups to 0 using kops edit

For the nodes

and set maxSize and minSize to 0

for the master, I had to figure my master by doing

Then, with the name of my master

and again set maxSize and minSize to 0

lastly, I had to update my cluster

Awesome, cluster is offline now! no need to go into AWS.

If you wanted to turn your cluster back on, rever the settings, changing your master to at least 1, and your nodes to your liking, I use 2.

VN:F [1.9.22_1171]
Rating: +7 (from 7 votes)

13 thoughts on “How to shutdown a kops Kubernetes cluster on AWS

    • I didn’t wanted to delete the whole cluster, just stop it, I want to keep all the other resources except the instances (DNS entries, volumes, ELBs, VPCs etc)

      VN:F [1.9.22_1171]
      Rating: 0 (from 0 votes)
  1. How to shutdown a kops Kubernetes cluster on AWS – [PERR0_HUNTER] | thechrisshort

  2. I must say it was hard to find your page in search results.
    You write awesome content but you should rank your blog higher in search
    engines. If you don’t know 2017 seo techniues search on youtube:
    how to rank a website Marcel’s way

    VA:F [1.9.22_1171]
    Rating: -4 (from 4 votes)
    • thanks for reporting this, I’m looking into the issue, I think my wordpress got compromised

      VN:F [1.9.22_1171]
      Rating: 0 (from 0 votes)
  3. I have noticed you don’t monetize your site, don’t waste your traffic, you can earn additional bucks every
    month. You can use the best adsense alternative for any type of website (they approve all websites),
    for more details simply search in gooogle: boorfe’s tips monetize your website

    VA:F [1.9.22_1171]
    Rating: -1 (from 1 vote)

Leave a Reply

Your email address will not be published. Required fields are marked *