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

Fix k8s version in examples and in validation #1626

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion docs/input-manifest/example.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
apiVersion: claudie.io/v1beta1
kind: InputManifest
metadata:
name: ExampleManifest
name: example-manifest
labels:
app.kubernetes.io/part-of: claudie
spec:
Expand Down
4 changes: 2 additions & 2 deletions docs/input-manifest/external-templates.md
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ Rolling updates of nodepools are performed when a change to a provider's externa
apiVersion: claudie.io/v1beta1
kind: InputManifest
metadata:
name: HetznerExampleManifest
name: hetzner-example-manifest
labels:
app.kubernetes.io/part-of: claudie
spec:
Expand Down Expand Up @@ -166,4 +166,4 @@ spec:
compute:
- compute-1-htz
- compute-2-htz
```
```
4 changes: 2 additions & 2 deletions docs/input-manifest/providers/aws.md
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ kubectl create secret generic aws-secret-1 --namespace=mynamespace --from-litera
apiVersion: claudie.io/v1beta1
kind: InputManifest
metadata:
name: AWSExampleManifest
name: aws-example-manifest
labels:
app.kubernetes.io/part-of: claudie
spec:
Expand Down Expand Up @@ -183,7 +183,7 @@ kubectl create secret generic aws-secret-2 --namespace=mynamespace --from-litera
apiVersion: claudie.io/v1beta1
kind: InputManifest
metadata:
name: AWSExampleManifest
name: aws-example-manifest
labels:
app.kubernetes.io/part-of: claudie
spec:
Expand Down
5 changes: 2 additions & 3 deletions docs/input-manifest/providers/azure.md
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ kubectl create secret generic azure-secret-1 --namespace=mynamespace --from-lite
apiVersion: claudie.io/v1beta1
kind: InputManifest
metadata:
name: AzureExampleManifest
name: azure-example-manifest
labels:
app.kubernetes.io/part-of: claudie
spec:
Expand Down Expand Up @@ -170,11 +170,10 @@ kubectl create secret generic azure-secret-2 --namespace=mynamespace --from-lite
```

```yaml
name: AzureExampleManifest
apiVersion: claudie.io/v1beta1
kind: InputManifest
metadata:
name: AzureExampleManifest
name: azure-example-manifest
labels:
app.kubernetes.io/part-of: claudie
spec:
Expand Down
4 changes: 2 additions & 2 deletions docs/input-manifest/providers/cloudflare.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ kubectl create secret generic aws-secret-1 --namespace=mynamespace --from-litera
apiVersion: claudie.io/v1beta1
kind: InputManifest
metadata:
name: CloudflareExampleManifest
name: cloudflare-example-manifest
labels:
app.kubernetes.io/part-of: claudie
spec:
Expand Down Expand Up @@ -105,4 +105,4 @@ spec:
pools:
- loadbalancer

```
```
4 changes: 2 additions & 2 deletions docs/input-manifest/providers/gcp.md
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ kubectl create secret generic gcp-secret-1 --namespace=mynamespace --from-litera
apiVersion: claudie.io/v1beta1
kind: InputManifest
metadata:
name: GCPExampleManifest
name: gcp-example-manifest
labels:
app.kubernetes.io/part-of: claudie
spec:
Expand Down Expand Up @@ -168,7 +168,7 @@ kubectl create secret generic gcp-secret-2 --namespace=mynamespace --from-litera
apiVersion: claudie.io/v1beta1
kind: InputManifest
metadata:
name: GCPExampleManifest
name: gcp-example-manifest
labels:
app.kubernetes.io/part-of: claudie
spec:
Expand Down
4 changes: 2 additions & 2 deletions docs/input-manifest/providers/hetzner.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ kubectl create secret generic hetzner-secret-1 --namespace=mynamespace --from-li
apiVersion: claudie.io/v1beta1
kind: InputManifest
metadata:
name: HetznerExampleManifest
name: hetzner-example-manifest
labels:
app.kubernetes.io/part-of: claudie
spec:
Expand Down Expand Up @@ -140,7 +140,7 @@ kubectl create secret generic hetzner-secret-2 --namespace=mynamespace --from-li
apiVersion: claudie.io/v1beta1
kind: InputManifest
metadata:
name: HetznerExampleManifest
name: hetzner-example-manifest
labels:
app.kubernetes.io/part-of: claudie
spec:
Expand Down
6 changes: 3 additions & 3 deletions docs/input-manifest/providers/oci.md
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ kubectl create secret generic oci-secret-1 --namespace=mynamespace --from-litera
apiVersion: claudie.io/v1beta1
kind: InputManifest
metadata:
name: OCIExampleManifest
name: oci-example-manifest
labels:
app.kubernetes.io/part-of: claudie
spec:
Expand Down Expand Up @@ -218,7 +218,7 @@ kubectl create secret generic oci-secret-2 --namespace=mynamespace --from-litera
apiVersion: claudie.io/v1beta1
kind: InputManifest
metadata:
name: OCIExampleManifest
name: oci-example-manifest
labels:
app.kubernetes.io/part-of: claudie
spec:
Expand Down Expand Up @@ -325,7 +325,7 @@ kubectl create secret generic oci-secret-1 --namespace=mynamespace --from-litera
apiVersion: claudie.io/v1beta1
kind: InputManifest
metadata:
name: OCIExampleManifest
name: oci-example-manifest
labels:
app.kubernetes.io/part-of: claudie
spec:
Expand Down
4 changes: 2 additions & 2 deletions docs/input-manifest/providers/on-prem.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ kubectl create secret generic static-node-key --namespace=mynamespace --from-fil
apiVersion: claudie.io/v1beta1
kind: InputManifest
metadata:
name: PrivateClusterExample
name: private-cluster-example
labels:
app.kubernetes.io/part-of: claudie
spec:
Expand Down Expand Up @@ -86,7 +86,7 @@ kubectl create secret generic static-node-key --namespace=mynamespace --from-fil
apiVersion: claudie.io/v1beta1
kind: InputManifest
metadata:
name: HybridCloudExample
name: hybrid-cloud-example
labels:
app.kubernetes.io/part-of: claudie
spec:
Expand Down
2 changes: 1 addition & 1 deletion docs/storage/storage-solution.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ To follow along, have a look at the example of `InputManifest` below.
apiVersion: claudie.io/v1beta1
kind: InputManifest
metadata:
name: ExampleManifestForStorageClasses
name: storageclass-example-manifest
labels:
app.kubernetes.io/part-of: claudie
spec:
Expand Down
1 change: 1 addition & 0 deletions docs/version-matrix/version-matrix.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,4 @@ In the following table, you can find the supported Kubernetes and OS versions fo
| v0.8.0 | 1.25.x, 1.26.x, 1.27.x | Ubuntu 22.04 |
| v0.8.1 | 1.27.x, 1.28.x, 1.29.x | Ubuntu 22.04 |
| v0.9.0 | 1.27.x, 1.28.x, 1.29.x, 1.30.x | Ubuntu 22.04 (Ubuntu 24.04 on Hetzner and Azure) |
| v0.9.1 | 1.29.x, 1.30.x 1.31.x | Ubuntu 22.04 (Ubuntu 24.04 on Hetzner and Azure) |
2 changes: 1 addition & 1 deletion internal/manifest/validate.go
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ func prettyPrintValidationError(err error) error {
case "cidrv4":
nerr = fmt.Errorf("field '%s' is required to have a valid CIDRv4 value", err.StructField())
case "ver":
nerr = fmt.Errorf("field '%s' is required to have a kubernetes version of: 1.27.x, 1.28.x, 1.29.x, 1.30.x", err.StructField())
nerr = fmt.Errorf("field '%s' is required to have a kubernetes version of: 1.29.x, 1.30.x, 1.31.x", err.StructField())
case "proxyMode":
nerr = fmt.Errorf("field '%s' is required to have a valid proxy mode value of \"on\", \"off\", \"default\"", err.StructField())
case "semver2":
Expand Down
2 changes: 1 addition & 1 deletion internal/manifest/validate_kubernetes.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ var (
// NOTE:
// first/second capturing group MUST be changed whenever new kubeone version is introduced in Claudie
// so validation will catch unsupported versions
kubernetesVersionRegexString = `^(1)\.(27|28|29|30)\.(0|[1-9]\d*)(?:-((?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\.(?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\+([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?$`
kubernetesVersionRegexString = `^(1)\.(29|30|31)\.(0|[1-9]\d*)(?:-((?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\.(?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\+([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?$`

// semverRegex is a regex using the semverRegexString.
// It's used to verify the version inside the manifest,
Expand Down
16 changes: 8 additions & 8 deletions manifests/claudie/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -57,18 +57,18 @@ apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
images:
- name: ghcr.io/berops/claudie/ansibler
newTag: d64a963-3199
newTag: a578c2e-3210
- name: ghcr.io/berops/claudie/autoscaler-adapter
newTag: c7475d5-3191
newTag: a578c2e-3210
- name: ghcr.io/berops/claudie/builder
newTag: c7475d5-3191
newTag: a578c2e-3210
- name: ghcr.io/berops/claudie/claudie-operator
newTag: c7475d5-3191
newTag: a578c2e-3210
- name: ghcr.io/berops/claudie/kube-eleven
newTag: c7475d5-3191
newTag: a578c2e-3210
- name: ghcr.io/berops/claudie/kuber
newTag: c7475d5-3191
newTag: a578c2e-3210
- name: ghcr.io/berops/claudie/manager
newTag: c7475d5-3191
newTag: a578c2e-3210
- name: ghcr.io/berops/claudie/terraformer
newTag: c7475d5-3191
newTag: a578c2e-3210
2 changes: 1 addition & 1 deletion manifests/testing-framework/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -91,4 +91,4 @@ secretGenerator:

images:
- name: ghcr.io/berops/claudie/testing-framework
newTag: c7475d5-3191
newTag: a578c2e-3210