From 9ead18f7a326cfd95e85871334f1929795f99620 Mon Sep 17 00:00:00 2001 From: unchama <11990197+unchama@users.noreply.github.com> Date: Sun, 3 Dec 2023 22:50:56 +0900 Subject: [PATCH 1/2] add --allow-experimental-api option --- .../ansible/roles/11-kubeadm-join-cp/tasks/main.yaml | 2 +- .../ansible/roles/12-kubeadm-join-wk/tasks/main.yaml | 2 +- seichi-onp-k8s/cluster-boot-up/scripts/nodes/k8s-node-setup.sh | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/seichi-onp-k8s/cluster-boot-up/ansible/roles/11-kubeadm-join-cp/tasks/main.yaml b/seichi-onp-k8s/cluster-boot-up/ansible/roles/11-kubeadm-join-cp/tasks/main.yaml index dd8af67c0..acae10b23 100644 --- a/seichi-onp-k8s/cluster-boot-up/ansible/roles/11-kubeadm-join-cp/tasks/main.yaml +++ b/seichi-onp-k8s/cluster-boot-up/ansible/roles/11-kubeadm-join-cp/tasks/main.yaml @@ -6,4 +6,4 @@ - name: Execute kubeadm join command become: yes - shell: "kubeadm join --config /root/join_kubeadm_cp.yaml" + shell: "kubeadm join --config /root/join_kubeadm_cp.yaml" --allow-experimental-api diff --git a/seichi-onp-k8s/cluster-boot-up/ansible/roles/12-kubeadm-join-wk/tasks/main.yaml b/seichi-onp-k8s/cluster-boot-up/ansible/roles/12-kubeadm-join-wk/tasks/main.yaml index 99a8841ed..72fbe5932 100644 --- a/seichi-onp-k8s/cluster-boot-up/ansible/roles/12-kubeadm-join-wk/tasks/main.yaml +++ b/seichi-onp-k8s/cluster-boot-up/ansible/roles/12-kubeadm-join-wk/tasks/main.yaml @@ -6,5 +6,5 @@ - name: Execute kubeadm join command become: yes - shell: "kubeadm join --config /root/join_kubeadm_wk.yaml" + shell: "kubeadm join --config /root/join_kubeadm_wk.yaml" --allow-experimental-api \ No newline at end of file diff --git a/seichi-onp-k8s/cluster-boot-up/scripts/nodes/k8s-node-setup.sh b/seichi-onp-k8s/cluster-boot-up/scripts/nodes/k8s-node-setup.sh index de6e0f78e..da4b8e50f 100644 --- a/seichi-onp-k8s/cluster-boot-up/scripts/nodes/k8s-node-setup.sh +++ b/seichi-onp-k8s/cluster-boot-up/scripts/nodes/k8s-node-setup.sh @@ -323,7 +323,7 @@ protectKernelDefaults: true EOF # Install Kubernetes without kube-proxy -kubeadm init --config "$HOME"/init_kubeadm.yaml --skip-phases=addon/kube-proxy --ignore-preflight-errors=NumCPU,Mem +kubeadm init --config "$HOME"/init_kubeadm.yaml --skip-phases=addon/kube-proxy --ignore-preflight-errors=NumCPU,Mem --allow-experimental-api mkdir -p "$HOME"/.kube cp -i /etc/kubernetes/admin.conf "$HOME"/.kube/config From 6958362fec4a902ebf228fbdab79b0918a4ec417 Mon Sep 17 00:00:00 2001 From: unchama <11990197+unchama@users.noreply.github.com> Date: Sun, 3 Dec 2023 22:51:13 +0900 Subject: [PATCH 2/2] add ens20 interface --- .../cluster-boot-up/scripts/nodes/k8s-node-setup.sh | 2 +- .../snippets/seichi-onp-k8s-cp-1-network.yaml | 6 ++++++ .../snippets/seichi-onp-k8s-cp-2-network.yaml | 6 ++++++ .../snippets/seichi-onp-k8s-cp-3-network.yaml | 6 ++++++ .../snippets/seichi-onp-k8s-wk-1-network.yaml | 6 ++++++ .../snippets/seichi-onp-k8s-wk-2-network.yaml | 6 ++++++ .../snippets/seichi-onp-k8s-wk-3-network.yaml | 6 ++++++ 7 files changed, 37 insertions(+), 1 deletion(-) diff --git a/seichi-onp-k8s/cluster-boot-up/scripts/nodes/k8s-node-setup.sh b/seichi-onp-k8s/cluster-boot-up/scripts/nodes/k8s-node-setup.sh index da4b8e50f..ca4bc450b 100644 --- a/seichi-onp-k8s/cluster-boot-up/scripts/nodes/k8s-node-setup.sh +++ b/seichi-onp-k8s/cluster-boot-up/scripts/nodes/k8s-node-setup.sh @@ -265,7 +265,7 @@ esac # Set kubeadm bootstrap token using openssl KUBEADM_BOOTSTRAP_TOKEN=$(openssl rand -hex 3).$(openssl rand -hex 8) -KUBEADM_LOCAL_ENDPOINT=$(ip -4 addr show ens19 | grep -oP '(?<=inet\s)\d+(\.\d+){3}' | awk 'NR==1{print $1}') +KUBEADM_LOCAL_ENDPOINT=$(ip -4 addr show ens20 | grep -oP '(?<=inet\s)\d+(\.\d+){3}' | awk 'NR==1{print $1}') # Set init configuration for the first control plane cat > "$HOME"/init_kubeadm.yaml <