Skip to content
This repository has been archived by the owner on Sep 15, 2023. It is now read-only.

Releases: pacoxu/kubeadm-operator

v0.1.0 support cross version upgrade

17 Jun 06:15
Compare
Choose a tag to compare

Quick start

https://github.com/pacoxu/kubeadm-operator#quick-start

daocloud.io/daocloud/kubeadm-operator:v0.1.0

Notice: for pod cannot restart kubelet, kubelet-reloadershould run on all cluster nodes as a daemon or process.

wget https://github.com/pacoxu/kubeadm-operator/releases/download/v0.1.0/kubelet-reloader-v0.2.0
chmod +x kubelet-reloader-v0.2.0
./kubelet-reloader-v0.2.0

#85 is for this problem.

Updates

  1. use debian instead of ubuntu as base image
  2. cross version upgration support like: v1.20 to v1.24 #73 (some samples here)
  3. add kubelet-reloader support & support renew specified commands #70

Tested Upgrade Version Matrix

initial version\ target version v1.21 v1.22 v1.23 v1.24
v1.21
v1.22 ✅✅ ✅✅ ✅✅
v1.23 ❌❌ ✅❌ ✅✅ ✅✅
v1.24 ❌❌ ❌❌ ✅❌ ✅✅
  • ✅✅ means supported and suggested
  • ✅❌ means supported but not suggested
  • ❌❌ means not supported and not suggested
  • Empty means no testing yet.

Due to my test, I only tested on v1.22-v1.24.

Tested(but not suggested)

  • v1.23 to v1.22 (change coredns version to v1.8.0 before applying the operation)
  • v1.24 to v1.23

known issue: node annotation may have extra prefix unix://; kubectl edit node to workaround.(v1.24 only)

#53 some sample operations yaml here

mvp version

06 Jun 06:55
Compare
Choose a tag to compare

#53

  • for kubeadm upgrade, kubelet cannot be restarted inside a pod, so user should run systemctl stop kubelet && /usr/bin/cp /usr/bin/kubelet-new /usr/bin/kubelet && systemctl restart kubelet if kubelet-new is newer. (If kubelet is replaced successful, just run systemctl restart kubelet)

v0.0.3

19 May 17:35
8bc13ed
Compare
Choose a tag to compare
make install
make deploy

Demo

For instance, I have a v1.23.6 cluster.

Actions

Create an operation like below:

apiVersion: operator.kubeadm.x-k8s.io/v1alpha1
kind: Operation
metadata:
  name: upgrade
spec:
  executionMode: Auto
  upgrade:
    kubernetesVersion: v1.23.5

After

[root@paco ~]# kubectl get operations,runtimetask,runtimetaskgroup
NAME                                          PHASE       GROUPS   SUCCEEDED   FAILED
operation.operator.kubeadm.x-k8s.io/upgrade   Succeeded   3        3

NAME                                                                  PHASE       STARTTIME   COMMAND   COMPLETIONTIME
runtimetask.operator.kubeadm.x-k8s.io/upgrade-01-upgrade-apply-paco   Succeeded   9h          3/3       9h

NAME                                                                  PHASE       NODES   SUCCEEDED   FAILED
runtimetaskgroup.operator.kubeadm.x-k8s.io/upgrade-01-upgrade-apply   Succeeded   1       1
runtimetaskgroup.operator.kubeadm.x-k8s.io/upgrade-02-upgrade-cp      Succeeded
runtimetaskgroup.operator.kubeadm.x-k8s.io/upgrade-02-upgrade-w       Succeeded

[root@paco ~]# kubectl version
Client Version: version.Info{Major:"1", Minor:"23", GitVersion:"v1.23.6", GitCommit:"ad3338546da947756e8a88aa6822e9c11e7eac22", GitTreeState:"clean", BuildDate:"2022-04-14T08:49:13Z", GoVersion:"go1.17.9", Compiler:"gc", Platform:"linux/amd64"}
Server Version: version.Info{Major:"1", Minor:"23", GitVersion:"v1.23.5", GitCommit:"c285e781331a3785a7f436042c65c5641ce8a9e9", GitTreeState:"clean", BuildDate:"2022-03-16T15:52:18Z", GoVersion:"go1.17.8", Compiler:"gc", Platform:"linux/amd64"}