Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add semver validation to Timoni's CUE schemas #266

Merged
merged 1 commit into from
Dec 3, 2023

Conversation

stefanprodan
Copy link
Owner

Add semver helper to Timoni's CUE schemas for enforcing a minimum Kubernetes minor version, e.g.:

clusterVersion: timoniv1.#SemVer{#Version: kubeVersion, #Minimum: "1.20.0"}

The above will fail on Kubernetes 1.18.0 with clusterVersion.minor: invalid value 18 (out of bound >=20).

On Kubernetes 1.28.4 the clusterVersion will output:

major:    1
minor:    28

@stefanprodan stefanprodan added the area/api API related issues and pull requests label Dec 3, 2023
@stefanprodan stefanprodan merged commit 3aa7e45 into main Dec 3, 2023
4 checks passed
@stefanprodan stefanprodan deleted the semver-validation branch December 3, 2023 17:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/api API related issues and pull requests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant