diff --git a/pkg/render/node.go b/pkg/render/node.go index a02f5546bf..4006aad1df 100644 --- a/pkg/render/node.go +++ b/pkg/render/node.go @@ -1037,6 +1037,7 @@ func (c *nodeComponent) nodeVolumes() []corev1.Volume { corev1.Volume{Name: "var-run", VolumeSource: corev1.VolumeSource{HostPath: &corev1.HostPathVolumeSource{Path: "/var/run"}}}, corev1.Volume{Name: "var-lib", VolumeSource: corev1.VolumeSource{HostPath: &corev1.HostPathVolumeSource{Path: "/var/lib"}}}, corev1.Volume{Name: "var-log", VolumeSource: corev1.VolumeSource{HostPath: &corev1.HostPathVolumeSource{Path: "/var/log"}}}, + corev1.Volume{Name: "proc-sys", VolumeSource: corev1.VolumeSource{HostPath: &corev1.HostPathVolumeSource{Path: "/proc/sys"}}}, ) } else { volumes = append(volumes, @@ -1306,6 +1307,7 @@ func (c *nodeComponent) nodeVolumeMounts() []corev1.VolumeMount { corev1.VolumeMount{MountPath: "/var/run", Name: "var-run"}, corev1.VolumeMount{MountPath: "/var/lib", Name: "var-lib"}, corev1.VolumeMount{MountPath: "/var/log", Name: "var-log"}, + corev1.VolumeMount{MountPath: "/nodeproc/sys", Name: "proc-sys"}, ) } else { nodeVolumeMounts = append(nodeVolumeMounts, diff --git a/pkg/render/node_test.go b/pkg/render/node_test.go index ca54d62217..411e601fa2 100644 --- a/pkg/render/node_test.go +++ b/pkg/render/node_test.go @@ -934,6 +934,7 @@ var _ = Describe("Node rendering tests", func() { {Name: "var-run", VolumeSource: corev1.VolumeSource{HostPath: &corev1.HostPathVolumeSource{Path: "/var/run"}}}, {Name: "var-lib", VolumeSource: corev1.VolumeSource{HostPath: &corev1.HostPathVolumeSource{Path: "/var/lib"}}}, {Name: "var-log", VolumeSource: corev1.VolumeSource{HostPath: &corev1.HostPathVolumeSource{Path: "/var/log"}}}, + {Name: "proc-sys", VolumeSource: corev1.VolumeSource{HostPath: &corev1.HostPathVolumeSource{Path: "/proc/sys"}}}, {Name: "xtables-lock", VolumeSource: corev1.VolumeSource{HostPath: &corev1.HostPathVolumeSource{Path: "/run/xtables.lock", Type: &fileOrCreate}}}, {Name: "cni-bin-dir", VolumeSource: corev1.VolumeSource{HostPath: &corev1.HostPathVolumeSource{Path: "/opt/cni/bin"}}}, {Name: "cni-net-dir", VolumeSource: corev1.VolumeSource{HostPath: &corev1.HostPathVolumeSource{Path: "/etc/cni/net.d"}}}, @@ -970,6 +971,7 @@ var _ = Describe("Node rendering tests", func() { {MountPath: "/var/run", Name: "var-run"}, {MountPath: "/var/lib", Name: "var-lib"}, {MountPath: "/var/log", Name: "var-log"}, + {MountPath: "/nodeproc/sys", Name: "proc-sys"}, {MountPath: "/var/run/nodeagent", Name: "policysync"}, {MountPath: "/etc/pki/tls/certs", Name: "tigera-ca-bundle", ReadOnly: true}, {MountPath: "/node-certs", Name: render.NodeTLSSecretName, ReadOnly: true},