Skip to content

Commit

Permalink
Specify the CNI mount in the host via a variable
Browse files Browse the repository at this point in the history
Signed-off-by: Miguel Duarte Barroso <[email protected]>
  • Loading branch information
maiqueb committed Feb 24, 2020
1 parent a393c66 commit ce36296
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
CNI_MOUNT_PATH ?= /host/opt/cni/bin
CNI_MOUNT_PATH ?= /opt/cni/bin

IMAGE_REGISTRY ?= quay.io/kubevirt
IMAGE_NAME ?= macvtap-cni
Expand Down
6 changes: 3 additions & 3 deletions templates/macvtap.yaml.in
Original file line number Diff line number Diff line change
Expand Up @@ -30,15 +30,15 @@ spec:
image: {{ .ImageRegistry }}/{{ .ImageName }}:{{ .ImageTag }}
securityContext:
privileged: true
command: ['cp', '/macvtap-cni', '{{ .CniMountPath }}/macvtap']
command: ['cp', '/macvtap-cni', '/host/opt/cni/bin/macvtap']
volumeMounts:
- name: cni
mountPath: {{ .CniMountPath }}
mountPath: /host/opt/cni/bin
mountPropagation: Bidirectional
volumes:
- name: deviceplugin
hostPath:
path: /var/lib/kubelet/device-plugins
- name: cni
hostPath:
path: /opt/cni/bin
path: {{ .CniMountPath }}

0 comments on commit ce36296

Please sign in to comment.