Compare commits

4 Commits

Author SHA1 Message Date
Doug Smith
18630fde0b Merge pull request #1424 from nirdothan/mount-multus-conf-dir
Thick client: mount multus-conf-dir
2025-05-13 08:32:26 -04:00
Nir Dothan
19f9283db4 Thick client: mount multus-conf-dir
Currently, the default CNI config dir is /etc/cni/multus/net.d [1].
However, pods do not mount this hostPath.
This issue only occurs when a delegate network-attachment-definition
has no spec, and it therefore needs to be loaded from disk[2].
For example, when deploying Istio-cni in multus mode,
the deployment creates an empty Istio-cni NAD in default namespace, while
the actual config is deployed on disk.
CmdAdd fails with the following error message:
GetNetworkDelegates: failed getting the delegate: GetCNIConfig:
err in GetCNIConfigFromFile: No networks found in /etc/cni/multus/net.d

[[1]](https://github.com/k8snetworkplumbingwg/multus-cni/blob/v4.2.0/pkg/types/conf.go#L38)
[[2]](https://github.com/k8snetworkplumbingwg/multus-cni/blob/v4.2.0/pkg/k8sclient/k8sclient.go#L506)

Signed-off-by: Nir Dothan <ndothan@redhat.com>
2025-05-05 17:45:52 +03:00
Doug Smith
1655d540cb Merge pull request #1418 from rollandf/baseimage
chore: update Dockerfile base image
2025-04-24 15:43:05 +02:00
Fred Rolland
96bfb26dac chore: update Dockerfile base image
- Fix CVEs

Signed-off-by: Fred Rolland <frolland@nvidia.com>
2025-04-06 16:31:47 +03:00
3 changed files with 7 additions and 2 deletions

View File

@@ -192,6 +192,8 @@ spec:
- name: hostroot
mountPath: /hostroot
mountPropagation: HostToContainer
- mountPath: /etc/cni/multus/net.d
name: multus-conf-dir
env:
- name: MULTUS_NODE_NAME
valueFrom:
@@ -247,3 +249,6 @@ spec:
- name: host-run-netns
hostPath:
path: /run/netns/
- name: multus-conf-dir
hostPath:
path: /etc/cni/multus/net.d

View File

@@ -8,7 +8,7 @@ ARG TARGETPLATFORM
RUN cd /usr/src/multus-cni && \
./hack/build-go.sh
FROM gcr.io/distroless/base-debian11:latest
FROM gcr.io/distroless/base-debian12:latest
LABEL org.opencontainers.image.source https://github.com/k8snetworkplumbingwg/multus-cni
COPY --from=build /usr/src/multus-cni/bin /usr/src/multus-cni/bin
COPY --from=build /usr/src/multus-cni/LICENSE /usr/src/multus-cni/LICENSE

View File

@@ -8,7 +8,7 @@ ARG TARGETPLATFORM
RUN cd /usr/src/multus-cni && \
./hack/build-go.sh
FROM gcr.io/distroless/base-debian11:debug
FROM gcr.io/distroless/base-debian12:debug
LABEL org.opencontainers.image.source https://github.com/k8snetworkplumbingwg/multus-cni
COPY --from=build /usr/src/multus-cni/bin /usr/src/multus-cni/bin
COPY --from=build /usr/src/multus-cni/LICENSE /usr/src/multus-cni/LICENSE