fix: multus fixes

This commit is contained in:
Stefan Reimer 2021-12-21 23:38:11 +01:00
parent 362fb2479d
commit 4048625b60
3 changed files with 22 additions and 6 deletions

View File

@ -2,7 +2,7 @@ apiVersion: v2
name: kubezero-network name: kubezero-network
description: KubeZero umbrella chart for all things network description: KubeZero umbrella chart for all things network
type: application type: application
version: 0.1.1 version: 0.1.3
home: https://kubezero.com home: https://kubezero.com
icon: https://cdn.zero-downtime.net/assets/kubezero/logo-small-64.png icon: https://cdn.zero-downtime.net/assets/kubezero/logo-small-64.png
keywords: keywords:

View File

@ -113,7 +113,6 @@ spec:
args: args:
- "--multus-conf-file=auto" - "--multus-conf-file=auto"
- "--cni-version=0.3.1" - "--cni-version=0.3.1"
- "--cni-bin-dir=/host/usr/libexec/cni"
resources: resources:
requests: requests:
cpu: "100m" cpu: "100m"
@ -131,9 +130,26 @@ spec:
- name: cni - name: cni
mountPath: /host/etc/cni/net.d mountPath: /host/etc/cni/net.d
- name: cnibin - name: cnibin
mountPath: /host/usr/libexec/cni mountPath: /host/opt/cni/bin
- name: multus-cfg - name: multus-cfg
mountPath: /tmp/multus-conf mountPath: /tmp/multus-conf
initContainers:
- name: install-multus-binary
image: ghcr.io/k8snetworkplumbingwg/multus-cni:{{ .Values.multus.tag }}
command:
- "cp"
- "/usr/src/multus-cni/bin/multus"
- "/host/opt/cni/bin/multus"
resources:
requests:
cpu: "10m"
memory: "15Mi"
securityContext:
privileged: true
volumeMounts:
- name: cnibin
mountPath: /host/opt/cni/bin
mountPropagation: Bidirectional
terminationGracePeriodSeconds: 10 terminationGracePeriodSeconds: 10
volumes: volumes:
- name: run - name: run
@ -144,7 +160,7 @@ spec:
path: /etc/cni/net.d path: /etc/cni/net.d
- name: cnibin - name: cnibin
hostPath: hostPath:
path: /usr/libexec/cni path: /opt/cni/bin
- name: multus-cfg - name: multus-cfg
configMap: configMap:
name: multus-cni-config name: multus-cni-config

View File

@ -145,7 +145,7 @@ if [ "$1" == 'upgrade' ]; then
# network # network
yq eval '.network // ""' ${HOSTFS}/etc/kubernetes/kubezero.yaml > _values.yaml yq eval '.network // ""' ${HOSTFS}/etc/kubernetes/kubezero.yaml > _values.yaml
helm template kubezero/kubezero-network --version 0.1.1 --include-crds --namespace kube-system --name-template network \ helm template kubezero/kubezero-network --version 0.1.3 --include-crds --namespace kube-system --name-template network \
-f _values.yaml --kube-version $KUBE_VERSION | kubectl apply -f - $LOG -f _values.yaml --kube-version $KUBE_VERSION | kubectl apply -f - $LOG
# addons # addons
@ -299,7 +299,7 @@ elif [[ "$1" =~ "^(bootstrap|recover|join)$" ]]; then
# network # network
yq eval '.network // ""' ${HOSTFS}/etc/kubernetes/kubezero.yaml > _values.yaml yq eval '.network // ""' ${HOSTFS}/etc/kubernetes/kubezero.yaml > _values.yaml
helm template kubezero/kubezero-network --version 0.1.1 --include-crds --namespace kube-system --name-template network \ helm template kubezero/kubezero-network --version 0.1.3 --include-crds --namespace kube-system --name-template network \
-f _values.yaml --kube-version $KUBE_VERSION | kubectl apply -f - $LOG -f _values.yaml --kube-version $KUBE_VERSION | kubectl apply -f - $LOG
# addons # addons