In this self-paced exercise, you will learn how to configure, deploy and test Karpenter within an Amazon EKS cluster using add-ons, blueprints and workloads.
Karpenter helps improve your application availability and cluster efficiency by rapidly launching right-sized compute resources in response to changing application loads. When Karpenter is installed in your cluster, Karpenter observes the aggregate resource requests of unscheduled pods and makes decisions to launch new nodes and terminate them to reduce scheduling latencies and infrastructure costs.
Karpenter is faster provisioning instances and scheduling pods than Cluster Autoscaler. Along with enhanced speed, Karpenter will choose the best suitable instance type for the required pod workloads. This leads to more efficient node sizing and reduced administrative configuration. Unlike Cluster Autoscaler, there is no need to configure and manage node groups for each instance type to be used, Karpenter has access to all instance types natively. Karpenter is considered to be faster and simplier to configure, however, it is only currently supported on AWS.
What Will You Do by Part¶
|Part||What will you do?|
|1||Setup and Configuration|
|2||Provision an Amazon EKS Cluster|
|3||Cluster Blueprint with Karpenter|
|4||Deploy a test Workload to the EKS cluster to activate Karpenter|
|5||Deprovision the EKS cluster|
Architecture & Design¶
- It is recommended to create a "dedicated managed node group" for system level resources and spot instance based nodes managed by Karpenter to run non-system level workloads.
- This configuration allows system level resources to take advantage of the consistency of on-demand or reserved instances while optimizing workload cost with performance.
In this excercise, we will create an EKS cluster that contains one managed node groups for system resources. The spot instances will be managed by Karpenter. A visual representation of this cluster design is shown below..
flowchart LR subgraph DATA[EKS Data Plane] direction TB subgraph NG1[System Node Group] direction RL i1[Rafay Operator] end subgraph NG2[Spot Nodes with Karpenter] direction RL f1[Workloads] end end CP[EKS Control Plane] <-.-> DATA
- You have access to an Amazon AWS account with privileges to create an IAM Role with the default Full IAM Policy to allow provisioning of resources on your behalf as part of the EKS cluster lifecycle.
- You have the AWS CLI installed and configured