Skip to content

Commit

Permalink
Added schema validation and notes to README
Browse files Browse the repository at this point in the history
  • Loading branch information
3pings committed Oct 21, 2024
1 parent ddb3791 commit 875792e
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 3 deletions.
9 changes: 8 additions & 1 deletion packs/karpenter-1.0.5/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Karpenter

Karpenter is an open-source node lifecycle management project built for Kubernetes. Adding Karpenter to a Kubernetes cluster can dramatically improve the efficiency and cost of running workloads on that cluster. Karpenter works by:
Karpenter is an open-source node lifecycle management project built for Kubernetes. Adding Karpenter to a Kubernetes cluster can dramatically improve the efficiency and cost of active workloads in the cluster. Karpenter automatically launches the right compute resources to handle your cluster's applications. Karpenter works by:

* Watching for pods that the Kubernetes scheduler has marked as unschedulable
* Evaluating scheduling constraints (resource requests, nodeselectors, affinities, tolerations, and topology spread constraints) requested by the pods
Expand All @@ -12,6 +12,11 @@ Karpenter is an open-source node lifecycle management project built for Kubernet
* Minimum Kubernetes Version is 1.25
* Pack support is for EKS only today.
* IRSA Roles must be created and used. Review the following section for additional guidance.
* AWS Account Number - This is a required value in the pack for annotations of the service account

### Pack Values

Provide your AWS Account Number in the `awsAccountNumber` value of the pack.

### AWS IAM Roles for Service Accounts (IRSA)

Expand Down Expand Up @@ -54,6 +59,8 @@ Karpenter uses tags in AWS to discover the resources needed to autoscale. Palet

## Usage

Make sure to checkout the [Karpenter Best Practices](https://aws.github.io/aws-eks-best-practices/karpenter/) when using Karpenter.

### Node Pool

```yaml
Expand Down
2 changes: 2 additions & 0 deletions packs/karpenter-1.0.5/schema.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
awsAccountNumber:
schema: '{{ required }}'
7 changes: 5 additions & 2 deletions packs/karpenter-1.0.5/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@ pack:
- image: public.ecr.aws/karpenter/controller:1.0.5
namespace: karpenter

# Provide your AWS account number below for karpenter annotations.
awsAccountNumber: ""

charts:
karpenter:
# -- Overrides the chart's name.
Expand All @@ -27,8 +30,8 @@ charts:
# If not set and create is true, a name is generated using the fullname template.
name: ""
# -- Additional annotations for the ServiceAccount.
annotations: {}
# "eks.amazonaws.com/role-arn": "arn:aws:iam::<AWS_ACCOUNT_NUMBER>:role/{{.spectro.system.cluster.name}}-karpenterControllerRole"
annotations:
"eks.amazonaws.com/role-arn": "arn:aws:iam::{{.spectro.pack.karpenter.awsAccountNumber}}:role/{{.spectro.system.cluster.name}}-karpenterControllerRole"
# -- Specifies additional rules for the core ClusterRole.
additionalClusterRoleRules: []
serviceMonitor:
Expand Down

0 comments on commit 875792e

Please sign in to comment.