From fafcca4168a91ac443f97fdb5f74180cd554c6d4 Mon Sep 17 00:00:00 2001 From: Anthony Date: Fri, 20 Oct 2023 02:10:14 -0400 Subject: [PATCH] #2014 Support k0s (#2015) * add containerd.sock path for k0s * Add changelog --- changelog.d/2014.added.md | 1 + mirrord/agent/src/runtime.rs | 4 +++- 2 files changed, 4 insertions(+), 1 deletion(-) create mode 100644 changelog.d/2014.added.md diff --git a/changelog.d/2014.added.md b/changelog.d/2014.added.md new file mode 100644 index 00000000000..d3e420bb3c3 --- /dev/null +++ b/changelog.d/2014.added.md @@ -0,0 +1 @@ +Added k0s support - add k0s containerd socket path. \ No newline at end of file diff --git a/mirrord/agent/src/runtime.rs b/mirrord/agent/src/runtime.rs index bddfb327b77..6a65fe0e44c 100644 --- a/mirrord/agent/src/runtime.rs +++ b/mirrord/agent/src/runtime.rs @@ -28,13 +28,15 @@ const CONTAINERD_DEFAULT_SOCK_PATH: &str = "/host/run/containerd/containerd.sock const CONTAINERD_ALTERNATIVE_SOCK_PATH: &str = "/host/run/dockershim.sock"; const CONTAINERD_K3S_SOCK_PATH: &str = "/host/run/k3s/containerd/containerd.sock"; const CONTAINERD_MICROK8S_SOCK_PATH: &str = "/host/var/snap/microk8s/common/run/containerd.sock"; +const CONTAINERD_K0S_SOCK_PATH: &str = "/host/run/k0s/containerd.sock"; /// Possible containerd socket paths, evaluated from left to right. -const CONTAINERD_SOCK_PATHS: [&str; 4] = [ +const CONTAINERD_SOCK_PATHS: [&str; 5] = [ CONTAINERD_DEFAULT_SOCK_PATH, CONTAINERD_ALTERNATIVE_SOCK_PATH, CONTAINERD_K3S_SOCK_PATH, CONTAINERD_MICROK8S_SOCK_PATH, + CONTAINERD_K0S_SOCK_PATH, ]; const DEFAULT_CONTAINERD_NAMESPACE: &str = "k8s.io";