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

Support Kubernetes 1.31.x #437

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Support Kubernetes 1.31.x #437

wants to merge 1 commit into from

Conversation

0x00ace
Copy link
Contributor

@0x00ace 0x00ace commented Oct 10, 2024

This PR adds support for Kubernetes 1.31.x

I have successfully booted a new Kubernetes cluster 1.31.1
Also, I have tested Kubernetes cluster upgrade from 1.30.2 -> 1.31.1

+--------------------------------------+-----------+---------+------------+--------------+-----------------+---------------+
| uuid                                 | name      | keypair | node_count | master_count | status          | health_status |
+--------------------------------------+-----------+---------+------------+--------------+-----------------+---------------+
| e475fe8d-394a-4eb3-af0f-68634f4927ab | cluster_1 | ace     |          2 |            3 | UPDATE_COMPLETE | HEALTHY       |
+--------------------------------------+-----------+---------+------------+--------------+-----------------+---------------+

Configuration:

  • RockyLinux 9
  • Cilium
  • OVN

CAPI versions:

NAME                       NAMESPACE                           TYPE                     CURRENT VERSION   NEXT VERSION
bootstrap-kubeadm          capi-kubeadm-bootstrap-system       BootstrapProvider        v1.8.4            Already up to date
control-plane-kubeadm      capi-kubeadm-control-plane-system   ControlPlaneProvider     v1.8.4            Already up to date
cluster-api                capi-system                         CoreProvider             v1.8.4            Already up to date
infrastructure-openstack   capo-system                         InfrastructureProvider   v0.10.5           Already up to date

Template:

os coe cluster template show k8s-v1.31.1-cilium-ovn
+-----------------------+-------------------------------------------------------------------------------------------------------------------------------------+
| Field                 | Value                                                                                                                               |
+-----------------------+-------------------------------------------------------------------------------------------------------------------------------------+
| insecure_registry     | -                                                                                                                                   |
| labels                | {'kube_tag': 'v1.31.1', 'container_infra_prefix': 'gitea.geekhome.org/public', 'fixed_subnet_cidr': '192.168.0.0/24',               |
|                       | 'octavia_provider': 'ovn'}                                                                                                          |
| updated_at            | -                                                                                                                                   |
| floating_ip_enabled   | False                                                                                                                               |
| fixed_subnet          | -                                                                                                                                   |
| master_flavor_id      | 2cpu4ram20hdd                                                                                                                       |
| uuid                  | c0dce5e1-c2d7-439f-a8a2-dc35d0eb0026                                                                                                |
| no_proxy              | -                                                                                                                                   |
| https_proxy           | -                                                                                                                                   |
| tls_disabled          | False                                                                                                                               |
| keypair_id            | -                                                                                                                                   |
| public                | False                                                                                                                               |
| http_proxy            | -                                                                                                                                   |
| docker_volume_size    | -                                                                                                                                   |
| server_type           | vm                                                                                                                                  |
| external_network_id   | vlan77                                                                                                                              |
| cluster_distro        | rockylinux                                                                                                                          |
| image_id              | rockylinux-9-kube-v1.31.1                                                                                                           |
| volume_driver         | -                                                                                                                                   |
| registry_enabled      | False                                                                                                                               |
| docker_storage_driver | overlay2                                                                                                                            |
| apiserver_port        | -                                                                                                                                   |
| name                  | k8s-v1.31.1-cilium-ovn                                                                                                              |
| created_at            | 2024-10-10T18:51:54+00:00                                                                                                           |
| network_driver        | cilium                                                                                                                              |
| fixed_network         | -                                                                                                                                   |
| coe                   | kubernetes                                                                                                                          |
| flavor_id             | 2cpu2ram20hdd                                                                                                                       |
| master_lb_enabled     | True                                                                                                                                |
| dns_nameserver        | 8.8.8.8,8.8.4.4                                                                                                                     |
| project_id            | aaed759d65f54702a6c319f89a7b2ce7                                                                                                    |
| hidden                | False                                                                                                                               |
| tags                  | -                                                                                                                                   |
+-----------------------+-------------------------------------------------------------------------------------------------------------------------------------+

Cluster nodes:

kubectl get nodes 
NAME                                          STATUS   ROLES                  AGE     VERSION
kube-n3t15-default-worker-j5xbh-n49x4-hwf4r   Ready    worker                 66m     v1.31.1
kube-n3t15-default-worker-j5xbh-n49x4-szrvq   Ready    worker                 2m49s   v1.31.1
kube-n3t15-jn27j-62vxv                        Ready    control-plane,master   84m     v1.31.1
kube-n3t15-jn27j-7jgpx                        Ready    control-plane,master   74m     v1.31.1
kube-n3t15-jn27j-gfbwv                        Ready    control-plane,master   65m     v1.31.1

Cluster pods status:

kubectl get pods -A 
NAMESPACE     NAME                                             READY   STATUS    RESTARTS      AGE
kube-system   cilium-49m7l                                     1/1     Running   0             66m
kube-system   cilium-6gs6j                                     1/1     Running   0             74m
kube-system   cilium-dvklr                                     1/1     Running   0             85m
kube-system   cilium-k8nd7                                     1/1     Running   0             3m9s
kube-system   cilium-operator-5bc9f6587c-5jptx                 1/1     Running   0             73m
kube-system   cilium-operator-5bc9f6587c-fcqjq                 1/1     Running   1 (62m ago)   82m
kube-system   cilium-wqcx4                                     1/1     Running   0             65m
kube-system   coredns-6644bf886c-4lmsn                         1/1     Running   0             65m
kube-system   coredns-6644bf886c-8mfhl                         1/1     Running   0             63m
kube-system   csi-cinder-controllerplugin-997ddd699-8bxwt      6/6     Running   1 (62m ago)   65m
kube-system   csi-cinder-nodeplugin-h794g                      3/3     Running   0             85m
kube-system   csi-cinder-nodeplugin-ltzfd                      3/3     Running   0             66m
kube-system   csi-cinder-nodeplugin-v94nz                      3/3     Running   0             65m
kube-system   csi-cinder-nodeplugin-vqqww                      3/3     Running   0             74m
kube-system   csi-cinder-nodeplugin-zqk5s                      3/3     Running   0             3m9s
kube-system   etcd-kube-n3t15-jn27j-62vxv                      1/1     Running   0             83m
kube-system   etcd-kube-n3t15-jn27j-7jgpx                      1/1     Running   0             74m
kube-system   etcd-kube-n3t15-jn27j-gfbwv                      1/1     Running   0             64m
kube-system   k8s-keystone-auth-7x4wm                          1/1     Running   1 (64m ago)   65m
kube-system   k8s-keystone-auth-r2zlm                          1/1     Running   0             84m
kube-system   k8s-keystone-auth-rrwkg                          1/1     Running   0             74m
kube-system   kube-apiserver-kube-n3t15-jn27j-62vxv            1/1     Running   0             83m
kube-system   kube-apiserver-kube-n3t15-jn27j-7jgpx            1/1     Running   0             73m
kube-system   kube-apiserver-kube-n3t15-jn27j-gfbwv            1/1     Running   0             64m
kube-system   kube-controller-manager-kube-n3t15-jn27j-62vxv   1/1     Running   0             83m
kube-system   kube-controller-manager-kube-n3t15-jn27j-7jgpx   1/1     Running   0             74m
kube-system   kube-controller-manager-kube-n3t15-jn27j-gfbwv   1/1     Running   0             64m
kube-system   kube-proxy-bl2xl                                 1/1     Running   0             61m
kube-system   kube-proxy-df8g6                                 1/1     Running   0             62m
kube-system   kube-proxy-nstf9                                 1/1     Running   0             3m9s
kube-system   kube-proxy-w5rsk                                 1/1     Running   0             61m
kube-system   kube-proxy-wdx8x                                 1/1     Running   0             62m
kube-system   kube-scheduler-kube-n3t15-jn27j-62vxv            1/1     Running   0             82m
kube-system   kube-scheduler-kube-n3t15-jn27j-7jgpx            1/1     Running   0             73m
kube-system   kube-scheduler-kube-n3t15-jn27j-gfbwv            1/1     Running   0             64m
kube-system   openstack-cloud-controller-manager-7twrp         1/1     Running   0             72m
kube-system   openstack-cloud-controller-manager-9lltv         1/1     Running   0             82m
kube-system   openstack-cloud-controller-manager-r97tb         1/1     Running   0             63m

Also I have to fix directory creation for keystone-kustomization - with -p flag there will be no error, if dir already exists

Copy link
Member

@okozachenko1203 okozachenko1203 left a comment

Choose a reason for hiding this comment

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

@0x00ace thanks for your contribution
we deprecated the in-tree image build utility and maintain a dedicated one https://github.com/vexxhost/capo-image-elements
Could you make a commit there also?

@okozachenko1203
Copy link
Member

thanks @yaguangtang
@0x00ace just for your info, vexxhost/capo-image-elements#8

@0x00ace
Copy link
Contributor Author

0x00ace commented Oct 12, 2024

@okozachenko1203 I will try, but the last time I used this capi image elements repo for Rocky Linux 9 image building my cluster was pretty unstable. So right now I'm using the official image builder.

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.

2 participants