<p>I'm having to build a demo Kubernetes cluster in AWS using Kubeadm.</p>
<p>Unfortunately, for several reasons, Kops, and EKS are out of the question in my current environment.</p>
<p>How do I deal with things such as auto-scaling and auto joining worker nodes back to the master if they get terminated for any reason? This is my main concern.</p>
<p>I've done this with Kops in the past and it's relatively straightforward, but I'm not sure how to manage using Kubeadm.</p>

<p><a href="https://github.com/kubernetes/autoscaler/tree/master/cluster-autoscaler#cluster-autoscaler" rel="nofollow noreferrer">Cluster Autoscaler</a> is what you are looking for to achieve it.</p>
<blockquote>
<p>Cluster Autoscaler is a tool that automatically adjusts the size of the Kubernetes cluster when one of the following conditions is true:
-there are pods that failed to run in the cluster due to insufficient resources.
-there are nodes in the cluster that have been underutilized for an extended period of time and their pods can be placed on other existing nodes.</p>
</blockquote>
<p>This tool will create and remove instances in ASG.</p>
<blockquote>
<p>Cluster Autoscaler requires the ability to examine and modify EC2 Auto Scaling Groups.</p>
</blockquote>
<p>You will only need add a template with a script for new created instances to add them to your cluster.</p>
<blockquote>
<p>If you use kubeadm to provision your cluster, it is up to you to automatically execute <code>kubeadm join</code> at boot time via some script</p>
</blockquote>
<p>If you have any questions about this tool, everything you can find in <a href="https://github.com/kubernetes/autoscaler/blob/master/cluster-autoscaler/FAQ.md#frequently-asked-questions" rel="nofollow noreferrer">FAQ</a></p>
<p>You can check documentation how to set up it on <a href="https://github.com/kubernetes/autoscaler/blob/master/cluster-autoscaler/cloudprovider/aws/README.md#cluster-autoscaler-on-aws" rel="nofollow noreferrer">AWS</a></p>
<blockquote>
<p>On AWS, Cluster Autoscaler utilizes Amazon EC2 Auto Scaling Groups to manage node groups. Cluster Autoscaler typically runs as a <code>Deployment</code> in your cluster.</p>
</blockquote>
