From 2dd42c52f79793cc9c2c1b00c7a62abb30536f36 Mon Sep 17 00:00:00 2001 From: Deepak Tiwari Date: Thu, 5 Sep 2019 15:35:42 -0500 Subject: [PATCH] neutron-sriov-agent: mount host sys-fs path in container Several sriov drivers (i.e. TaaS, Trunking) require the write permissions to files in /sys/class/net/ and /sys/devices. This patchset mounts the host's above mentioned sys-fs folders for the neutron-sriov-agent container. Change-Id: I87f51d1ad46bb272beb9401f2b428c81c3dc6f69 --- neutron/templates/daemonset-sriov-agent.yaml | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/neutron/templates/daemonset-sriov-agent.yaml b/neutron/templates/daemonset-sriov-agent.yaml index 73f760910e..6b715a6fd2 100644 --- a/neutron/templates/daemonset-sriov-agent.yaml +++ b/neutron/templates/daemonset-sriov-agent.yaml @@ -141,6 +141,10 @@ spec: command: - /tmp/neutron-sriov-agent.sh volumeMounts: + - mountPath: /sys/class/net + name: host-sys-class-net + - mountPath: /sys/devices + name: host-sys-devices - name: pod-tmp mountPath: /tmp - name: neutron-bin @@ -206,6 +210,12 @@ spec: mountPath: /run {{ if $mounts_neutron_sriov_agent.volumeMounts }}{{ toYaml $mounts_neutron_sriov_agent.volumeMounts | indent 12 }}{{ end }} volumes: + - name: host-sys-class-net + hostPath: + path: /sys/class/net + - name: host-sys-devices + hostPath: + path: /sys/devices - name: pod-tmp emptyDir: {} - name: pod-shared