Skip to content

Commit

Permalink
Support Kubernetes 1.31.x (#437)
Browse files Browse the repository at this point in the history
* Support Kubernetes 1.31.x

* Add 1.31 jobs

---------

Co-authored-by: Mohammed Naser <[email protected]>
  • Loading branch information
0x00ace and mnaser authored Oct 14, 2024
1 parent eceb996 commit 824fb57
Show file tree
Hide file tree
Showing 5 changed files with 35 additions and 22 deletions.
6 changes: 6 additions & 0 deletions magnum_cluster_api/cmd/image_loader.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@
"v1.28.11",
"v1.29.6",
"v1.30.2",
"v1.31.1",
]


Expand Down Expand Up @@ -245,6 +246,11 @@ def _get_cloud_provider_images():
"registry.k8s.io/provider-os/cinder-csi-plugin:v1.30.0",
"registry.k8s.io/provider-os/manila-csi-plugin:v1.30.0",
"registry.k8s.io/provider-os/openstack-cloud-controller-manager:v1.30.0",
# v1.31.1
"registry.k8s.io/provider-os/k8s-keystone-auth:v1.31.1",
"registry.k8s.io/provider-os/cinder-csi-plugin:v1.31.1",
"registry.k8s.io/provider-os/manila-csi-plugin:v1.31.1",
"registry.k8s.io/provider-os/openstack-cloud-controller-manager:v1.31.1",
]


Expand Down
5 changes: 5 additions & 0 deletions magnum_cluster_api/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,11 @@
default="$image_repository/cluster-autoscaler:v1.30.1",
help="Image for the cluster auto-scaler for Kubernetes v1.30.",
),
cfg.StrOpt(
"v1_31_image",
default="$image_repository/cluster-autoscaler:v1.31.0",
help="Image for the cluster auto-scaler for Kubernetes v1.31.",
),
]


Expand Down
2 changes: 2 additions & 0 deletions magnum_cluster_api/integrations/common.py
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,8 @@ def get_cloud_provider_tag(cluster: objects.Cluster, label: str) -> str:
tag = "v1.29.0"
elif version.major == 1 and version.minor == 30:
tag = "v1.30.0"
elif version.major == 1 and version.minor == 31:
tag = "v1.31.1"

if tag is None:
raise ValueError(
Expand Down
2 changes: 1 addition & 1 deletion magnum_cluster_api/resources.py
Original file line number Diff line number Diff line change
Expand Up @@ -2039,7 +2039,7 @@ def get_object(self) -> objects.ClusterClass:
{
"op": "add",
"path": "/spec/template/spec/kubeadmConfigSpec/preKubeadmCommands/-",
"value": "mkdir /etc/kubernetes/keystone-kustomization",
"value": "mkdir -p /etc/kubernetes/keystone-kustomization",
},
{
"op": "add",
Expand Down
42 changes: 21 additions & 21 deletions zuul.d/jobs-ubuntu-2204.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,25 +6,6 @@
image_operating_system: ubuntu-2204
image_os_distro: ubuntu

- job:
name: magnum-cluster-api-sonobuoy-ubuntu-2204-v1.27.15
parent: magnum-cluster-api-sonobuoy-ubuntu-2204
vars:
kube_tag: v1.27.15
image_url: https://static.atmosphere.dev/artifacts/magnum-cluster-api/ubuntu-jammy-kubernetes-1-27-15-1719601165.qcow2

- job:
name: magnum-cluster-api-sonobuoy-ubuntu-2204-v1.27.15-calico
parent: magnum-cluster-api-sonobuoy-ubuntu-2204-v1.27.15
vars:
network_driver: calico

- job:
name: magnum-cluster-api-sonobuoy-ubuntu-2204-v1.27.15-cilium
parent: magnum-cluster-api-sonobuoy-ubuntu-2204-v1.27.15
vars:
network_driver: cilium

- job:
name: magnum-cluster-api-sonobuoy-ubuntu-2204-v1.28.11
parent: magnum-cluster-api-sonobuoy-ubuntu-2204
Expand Down Expand Up @@ -82,15 +63,34 @@
vars:
network_driver: cilium

- job:
name: magnum-cluster-api-sonobuoy-ubuntu-2204-v1.31.1
parent: magnum-cluster-api-sonobuoy-ubuntu-2204
vars:
kube_tag: v1.31.1
image_url: https://static.atmosphere.dev/artifacts/magnum-cluster-api/ubuntu-jammy-kubernetes-1-31-1-1728920853.qcow2

- job:
name: magnum-cluster-api-sonobuoy-ubuntu-2204-v1.31.1-calico
parent: magnum-cluster-api-sonobuoy-ubuntu-2204-v1.31.1
vars:
network_driver: calico

- job:
name: magnum-cluster-api-sonobuoy-ubuntu-2204-v1.31.1-cilium
parent: magnum-cluster-api-sonobuoy-ubuntu-2204-v1.31.1
vars:
network_driver: cilium

- project-template:
name: magnum-cluster-api-ubuntu-2204
check:
jobs:
- magnum-cluster-api-sonobuoy-ubuntu-2204-v1.27.15-calico
- magnum-cluster-api-sonobuoy-ubuntu-2204-v1.27.15-cilium
- magnum-cluster-api-sonobuoy-ubuntu-2204-v1.28.11-calico
- magnum-cluster-api-sonobuoy-ubuntu-2204-v1.28.11-cilium
- magnum-cluster-api-sonobuoy-ubuntu-2204-v1.29.6-calico
- magnum-cluster-api-sonobuoy-ubuntu-2204-v1.29.6-cilium
- magnum-cluster-api-sonobuoy-ubuntu-2204-v1.30.2-calico
- magnum-cluster-api-sonobuoy-ubuntu-2204-v1.30.2-cilium
- magnum-cluster-api-sonobuoy-ubuntu-2204-v1.31.1-calico
- magnum-cluster-api-sonobuoy-ubuntu-2204-v1.31.1-cilium

0 comments on commit 824fb57

Please sign in to comment.