Skip to content

sks: add commands to generate karpenter-related manifests - #905

Merged
ylmrx merged 4 commits into
masterfrom
ylamouroux/sc-195510/karpenter-manifest-generation
Sep 1, 2026
Merged

sks: add commands to generate karpenter-related manifests#905
ylmrx merged 4 commits into
masterfrom
ylamouroux/sc-195510/karpenter-manifest-generation

Conversation

@ylmrx

@ylmrx ylmrx commented Sep 1, 2026

Copy link
Copy Markdown
Contributor

Description

Add a new generate-karpenter-manifests command in the compute/sks context.

It generates the kubernetes resources needed to enable Karpenter on a given cluster.

The code is displayed on the standard output.

Two flags allow to further tweak the command behavior:

  • --nodepool (-n): only display the NodePool resource
  • --exoscale-nodeclass (-e): only display the ExoscaleNodeClass resource

When no flags are given, both are assumed, thus both resources are displayed.

Checklist

(For exoscale contributors)

  • Changelog updated (under Unreleased block, and add the Pull Request #number for each bit you add to the CHANGELOG.md)
  • Testing

Testing

The command was extensively tried out on a preprod cluster.

$ ./cli compute sks generate-karpenter-manifests asd136 --zone nowhere
error: switch client zone v3: get zone api endpoint: find zone: "nowhere" not
found in ListZonesResponse: Not Found
$ ./cli compute sks km not-existant         
error: "not-existant" not found in ListSKSClustersResponse: Not Found
$ ./cli compute sks km asd136 ## [1]
---
apiVersion: karpenter.exoscale.com/v1
kind: ExoscaleNodeClass
(...)
---
apiVersion: karpenter.sh/v1
kind: NodePool
(...)
$ ./cli compute sks km asd136 -e            
---
apiVersion: karpenter.exoscale.com/v1
kind: ExoscaleNodeClass
(...)
$ ./cli compute sks km asd136 -n 
---
apiVersion: karpenter.sh/v1
kind: NodePool
(...)
$ ./cli compute sks km asd136 -ne ## (identical to [1])
---
apiVersion: karpenter.exoscale.com/v1
kind: ExoscaleNodeClass
(...)
---
apiVersion: karpenter.sh/v1
kind: NodePool
(...)

@PhilippeChepy PhilippeChepy left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@nerzhul

nerzhul commented Sep 1, 2026

Copy link
Copy Markdown
Contributor

i'd call it generate-karpenter-manifests

@ylmrx
ylmrx merged commit f140418 into master Sep 1, 2026
7 checks passed
@ylmrx
ylmrx deleted the ylamouroux/sc-195510/karpenter-manifest-generation branch September 1, 2026 15:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants