forked from kubevirt/macvtap-cni
-
Notifications
You must be signed in to change notification settings - Fork 0
/
macvtap.yaml.in
56 lines (56 loc) · 1.5 KB
/
macvtap.yaml.in
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
apiVersion: apps/v1
kind: DaemonSet
metadata:
name: macvtap-cni
namespace: '{{ .Namespace }}'
spec:
selector:
matchLabels:
name: macvtap-cni
template:
metadata:
labels:
name: macvtap-cni
spec:
hostNetwork: true
hostPID: true
priorityClassName: system-node-critical
containers:
- name: macvtap-cni
command: ["/macvtap-deviceplugin", "-v", "3", "-logtostderr"]
envFrom:
- configMapRef:
name: '{{ .DevicePluginConfigName }}'
image: '{{ .MacvtapImage }}'
imagePullPolicy: '{{ .ImagePullPolicy }}'
resources:
requests:
cpu: "60m"
memory: "30Mi"
securityContext:
privileged: true
volumeMounts:
- name: deviceplugin
mountPath: /var/lib/kubelet/device-plugins
initContainers:
- name: install-cni
command: ["cp", "/macvtap-cni", "/host/opt/cni/bin/macvtap"]
image: '{{ .MacvtapImage }}'
imagePullPolicy: '{{ .ImagePullPolicy }}'
resources:
requests:
cpu: "10m"
memory: "15Mi"
securityContext:
privileged: true
volumeMounts:
- name: cni
mountPath: /host/opt/cni/bin
mountPropagation: Bidirectional
volumes:
- name: deviceplugin
hostPath:
path: /var/lib/kubelet/device-plugins
- name: cni
hostPath:
path: '{{ .CniMountPath }}'