From e5b45054856a45f766999839afffc5e3fb893cd2 Mon Sep 17 00:00:00 2001 From: liujian <54946465+redscholar@users.noreply.github.com> Date: Fri, 28 Mar 2025 15:40:08 +0800 Subject: [PATCH] feat: change default criSocket to docker (#2517) Signed-off-by: joyceliu Co-authored-by: joyceliu --- config/capkk/release/cluster-template.yaml | 6 +++--- pkg/controllers/infrastructure/inventory_controller.go | 3 ++- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/config/capkk/release/cluster-template.yaml b/config/capkk/release/cluster-template.yaml index 933a170b..34aae3c8 100644 --- a/config/capkk/release/cluster-template.yaml +++ b/config/capkk/release/cluster-template.yaml @@ -45,10 +45,10 @@ spec: kubeadmConfigSpec: initConfiguration: nodeRegistration: - criSocket: ${CRI_SOCKET=unix:///var/run/containerd/containerd.sock} + criSocket: ${CRI_SOCKET=unix:///run/containerd/containerd.sock} joinConfiguration: nodeRegistration: - criSocket: ${CRI_SOCKET=unix:///var/run/containerd/containerd.sock} + criSocket: ${CRI_SOCKET=unix:///run/containerd/containerd.sock} --- apiVersion: infrastructure.cluster.x-k8s.io/v1beta1 kind: KKMachineTemplate @@ -104,4 +104,4 @@ spec: spec: joinConfiguration: nodeRegistration: - criSocket: ${CRI_SOCKET=unix:///var/run/containerd/containerd.sock} + criSocket: ${CRI_SOCKET=unix:///run/containerd/containerd.sock} diff --git a/pkg/controllers/infrastructure/inventory_controller.go b/pkg/controllers/infrastructure/inventory_controller.go index 42c11fd2..bba37f7e 100644 --- a/pkg/controllers/infrastructure/inventory_controller.go +++ b/pkg/controllers/infrastructure/inventory_controller.go @@ -262,7 +262,8 @@ func (r *InventoryReconciler) reconcileNormal(ctx context.Context, scope *cluste func (r *InventoryReconciler) reconcileInventoryPlaybook(ctx context.Context, scope *clusterScope) error { // get playbook from inventory if scope.Inventory.Annotations[kkcorev1.HostCheckPlaybookAnnotation] == "" { - return nil + // cannot find playbook. should create it + return r.createHostCheckPlaybook(ctx, scope) } playbook := &kkcorev1.Playbook{} if err := r.Client.Get(ctx, ctrlclient.ObjectKey{Name: scope.Inventory.Annotations[kkcorev1.HostCheckPlaybookAnnotation], Namespace: scope.Namespace}, playbook); err != nil {