{"repo":"aws/aws-node-termination-handler","free":true,"listed":false,"github":"https://github.com/aws/aws-node-termination-handler","clone":"git clone https://github.com/aws/aws-node-termination-handler.git","description":"Gracefully handle EC2 instance shutdown within Kubernetes","language":"Go","stars":1763,"topics":["kubernetes","aws-ec2","spot-instances","eks","golang","maintenance-events"],"license":"Apache-2.0","category":"deployment-docker-iac","readme_excerpt":"AWS Node Termination Handler Gracefully handle EC2 instance shutdown within Kubernetes Project Summary This project ensures that the Kubernetes control plane responds appropriately to events that can cause your EC2 instance to become unavailable, such as EC2 maintenance events, EC2 Spot interruptions, ASG Scale-In, ASG AZ Rebalance, and EC2 Instance Termination via the API or Console. If not handled, your application code may not stop gracefully, take longer to recover full availability, or accidentally schedule work to nodes that are going down. The aws-node-termination-handler (NTH) can operate in two different modes: Instance Metadata Service (IMDS) or the Queue Processor. The aws-node-termination-handler Instance Metadata Service Monitor will run a small pod on each host to perform monitoring of IMDS paths like /spot or /events and react accordingly to drain and/or cordon the corresponding node. The aws-node-termination-handler Queue Processor will monitor an SQS queue of events from Amazon EventBridge for ASG lifecycle events, EC2 status change events, Spot Interruption Termination Notice events, and Spot Rebalance Recommendation events. When NTH detects an instance is going down, we use the Kubernetes API to cordon the node to ensure no new work is scheduled there, then drain it, removing any existing work. The termination handler Queue Processor requires AWS IAM permissions to monitor and manage the SQS queue and to query the EC2 API. You can run the termination handle","default_branch":null,"files":null,"tree":[],"storefront":"/r/aws","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/aws/aws-node-termination-handler/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}