Skip to content

[GEP-33] Add Capability support - #206

Open
aniruddha2000 wants to merge 11 commits into
mainfrom
add-capability
Open

[GEP-33] Add Capability support#206
aniruddha2000 wants to merge 11 commits into
mainfrom
add-capability

Conversation

@aniruddha2000

Copy link
Copy Markdown
Member

How to categorize this PR?

/kind api-change
/kind enhancement

What this PR does / why we need it:

This PR is part of GEP-33 Machine Image Capabilities

It adopts the introduced Cloud Profile Capabilities from Gardener. It offers a mechanism to define a relationships between MachineTypes and MachineImages to ensure only compatible amis are selected for a given MachineType. An example for a Capability is the CPU architecture that is added as the first mandatory Capability. The existing architecture field is planned to be removed eventually.

Which issue(s) this PR fixes:
Fixes #

Special notes for your reviewer:

Breaking changes:

@ske-prow

ske-prow Bot commented Jul 9, 2026

Copy link
Copy Markdown

Skipping CI for Draft Pull Request.
If you want CI signal for your change, please convert it to an actual PR.
You can still manually trigger a test run with /test all

@ske-prow ske-prow Bot added do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. kind/api-change API change with impact on API users kind/enhancement Enhancement, improvement, extension labels Jul 9, 2026
@ske-prow

ske-prow Bot commented Jul 9, 2026

Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign nschad for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@ske-prow ske-prow Bot added the size/M Denotes a PR that changes 30-99 lines, ignoring generated files. label Jul 9, 2026
@ske-prow ske-prow Bot added size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. and removed size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Jul 13, 2026
@ske-prow ske-prow Bot added size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. and removed size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. labels Jul 22, 2026
@aniruddha2000
aniruddha2000 marked this pull request as ready for review July 23, 2026 07:14
@ske-prow ske-prow Bot added needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. and removed do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. labels Jul 23, 2026
@ske-prow ske-prow Bot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Jul 24, 2026
@nschad

nschad commented Jul 30, 2026

Copy link
Copy Markdown
Contributor

/hold

risk of regression. needs heavy-testing

@ske-prow ske-prow Bot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jul 30, 2026
Comment thread pkg/controller/worker/machines.go Outdated

@timebertt timebertt 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.

In general, this PR is very hard to review.
We had a look together with @breuerfelix @viragvoros @nschad, but haven't made it through all of it. We had a look at the API types, helpers and some parts of the validation.

Comment thread pkg/apis/stackit/v1alpha1/types_cloudprofile.go
Comment thread pkg/apis/stackit/v1alpha1/types_cloudprofile.go
Comment thread pkg/apis/stackit/v1alpha1/types_cloudprofile.go
Comment thread pkg/apis/stackit/v1alpha1/types_cloudprofile.go
Comment thread pkg/apis/stackit/v1alpha1/types_worker.go
Comment thread pkg/apis/stackit/validation/cloudprofile.go
Comment thread pkg/admission/validator/namespacedcloudprofile.go Outdated
Comment thread pkg/admission/validator/namespacedcloudprofile.go Outdated
Comment thread pkg/admission/validator/namespacedcloudprofile.go Outdated
return allErrs
}

func validateMachineImageCapabilities(machineImage core.MachineImage, version gardencorev1beta1.MachineImageVersion, providerImageVersion stackitv1alpha1.MachineImageVersion, capabilityDefinitions []gardencorev1beta1.CapabilityDefinition) field.ErrorList {

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.

Why is the entire validation for NamespacedCloudProfiles implemented in this package, while validation for CloudProfiles is implemented in the dedicated validation package?
Can we consolidate this? (Could also be in a separate PR)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

will be done in a seperate PR

@nschad
nschad force-pushed the add-capability branch 3 times, most recently from 6065917 to b46da81 Compare August 4, 2026 10:54
@ske-prow ske-prow Bot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Aug 12, 2026
nschad added 2 commits August 12, 2026 15:02
Signed-off-by: Niclas Schad <niclas.schad@stackit.cloud>
@nschad
nschad force-pushed the add-capability branch 2 times, most recently from 34917b9 to fcca803 Compare August 12, 2026 13:02
@ske-prow ske-prow Bot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Aug 12, 2026
Comment thread pkg/apis/stackit/validation/cloudprofile.go Outdated
Comment thread pkg/apis/stackit/validation/cloudprofile.go Outdated
Comment thread pkg/controller/worker/machines.go Outdated
Comment thread pkg/controller/worker/machines.go Outdated
nschad added 3 commits August 20, 2026 13:53
Signed-off-by: Niclas Schad <niclas.schad@stackit.cloud>
…ype as default" and move to seperate PR

Signed-off-by: Niclas Schad <niclas.schad@stackit.cloud>
Signed-off-by: Niclas Schad <niclas.schad@stackit.cloud>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. kind/api-change API change with impact on API users kind/enhancement Enhancement, improvement, extension size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants