2021-12-01 12:35:18 +00:00
|
|
|
{{- if .Values.multus.enabled }}
|
|
|
|
apiVersion: apps/v1
|
|
|
|
kind: DaemonSet
|
|
|
|
metadata:
|
|
|
|
name: kube-multus-ds
|
|
|
|
namespace: kube-system
|
|
|
|
labels:
|
2022-07-14 14:59:06 +00:00
|
|
|
{{- include "kubezero-lib.labels" . | nindent 4 }}
|
2021-12-01 12:35:18 +00:00
|
|
|
spec:
|
|
|
|
selector:
|
|
|
|
matchLabels:
|
2022-07-14 14:59:06 +00:00
|
|
|
{{- include "kubezero-lib.selectorLabels" . | nindent 6 }}
|
2021-12-01 12:35:18 +00:00
|
|
|
updateStrategy:
|
|
|
|
type: RollingUpdate
|
|
|
|
template:
|
|
|
|
metadata:
|
|
|
|
labels:
|
2022-07-14 14:59:06 +00:00
|
|
|
{{- include "kubezero-lib.labels" . | nindent 8 }}
|
2021-12-01 12:35:18 +00:00
|
|
|
spec:
|
|
|
|
hostNetwork: true
|
|
|
|
tolerations:
|
|
|
|
- operator: Exists
|
|
|
|
effect: NoSchedule
|
2022-01-28 16:22:39 +00:00
|
|
|
- operator: Exists
|
|
|
|
effect: NoExecute
|
2021-12-01 12:35:18 +00:00
|
|
|
serviceAccountName: multus
|
|
|
|
containers:
|
|
|
|
- name: kube-multus
|
|
|
|
image: ghcr.io/k8snetworkplumbingwg/multus-cni:{{ .Values.multus.tag }}
|
|
|
|
command: ["/entrypoint.sh"]
|
|
|
|
args:
|
2022-07-14 14:59:06 +00:00
|
|
|
- "--multus-conf-file=/tmp/multus-conf/00-multus.conf"
|
|
|
|
- "--rename-conf-file=false"
|
2022-04-08 15:11:34 +00:00
|
|
|
- "--cni-bin-dir=/host/usr/libexec/cni"
|
2021-12-01 12:35:18 +00:00
|
|
|
- "--cni-version=0.3.1"
|
|
|
|
resources:
|
|
|
|
requests:
|
|
|
|
cpu: "100m"
|
|
|
|
memory: "50Mi"
|
|
|
|
limits:
|
|
|
|
cpu: "100m"
|
|
|
|
memory: "50Mi"
|
|
|
|
securityContext:
|
|
|
|
privileged: true
|
2021-12-21 15:05:08 +00:00
|
|
|
capabilities:
|
|
|
|
add: ["SYS_ADMIN"]
|
2021-12-01 12:35:18 +00:00
|
|
|
volumeMounts:
|
2021-12-21 15:05:08 +00:00
|
|
|
- name: run
|
|
|
|
mountPath: /run
|
2021-12-01 12:35:18 +00:00
|
|
|
- name: cni
|
|
|
|
mountPath: /host/etc/cni/net.d
|
|
|
|
- name: cnibin
|
2022-04-08 15:11:34 +00:00
|
|
|
mountPath: /host/usr/libexec/cni
|
2021-12-01 12:35:18 +00:00
|
|
|
- name: multus-cfg
|
|
|
|
mountPath: /tmp/multus-conf
|
|
|
|
terminationGracePeriodSeconds: 10
|
|
|
|
volumes:
|
2021-12-21 15:05:08 +00:00
|
|
|
- name: run
|
|
|
|
hostPath:
|
|
|
|
path: /run
|
2021-12-01 12:35:18 +00:00
|
|
|
- name: cni
|
|
|
|
hostPath:
|
|
|
|
path: /etc/cni/net.d
|
|
|
|
- name: cnibin
|
|
|
|
hostPath:
|
2022-04-08 15:11:34 +00:00
|
|
|
path: /usr/libexec/cni
|
2021-12-01 12:35:18 +00:00
|
|
|
- name: multus-cfg
|
|
|
|
configMap:
|
|
|
|
name: multus-cni-config
|
|
|
|
items:
|
|
|
|
- key: cni-conf.json
|
2022-07-14 14:59:06 +00:00
|
|
|
path: 00-multus.conf
|
2021-12-01 12:35:18 +00:00
|
|
|
{{- end }}
|