Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request: Multus configuration add namespace isolation #11594

Closed
Sispheor opened this issue Oct 2, 2024 · 4 comments · Fixed by #11605
Closed

Feature request: Multus configuration add namespace isolation #11594

Sispheor opened this issue Oct 2, 2024 · 4 comments · Fixed by #11605
Labels
kind/feature Categorizes issue or PR as related to a new feature.

Comments

@Sispheor
Copy link
Contributor

Sispheor commented Oct 2, 2024

What would you like to be added

Seems that we can only enable multus and then use it with the default config.
It works fine but we could move one step further by adding the possibility to configure it (/etc/cni/net.d/) like described in the doc.

Why is this needed

For example, by default Multus networks config are only namespace scoped. So we cannot decalre a network config once in a dedicated namesapace to be then consumed in all other NS.
To do that we need to set the "namespaceIsolation" flag to true in the conf.

@Sispheor Sispheor added the kind/feature Categorizes issue or PR as related to a new feature. label Oct 2, 2024
@Sispheor
Copy link
Contributor Author

Sispheor commented Oct 2, 2024

Sorry, the config is actually available from the host (workers) in /etc/cni/net.d/00-multus.conf.

But overridden on pod start.

@Sispheor
Copy link
Contributor Author

Sispheor commented Oct 2, 2024

I've added my flag to the daemon set and it works.

      containers:
      - name: kube-multus
        image: {{ multus_image_repo }}:{{ multus_image_tag }}
        command: ["/thin_entrypoint"]
        args:
        - "--cni-conf-dir={{ multus_cni_conf_dir }}"
        - "--multus-autoconfig-dir={{ multus_cni_conf_dir }}"
        - "--cni-bin-dir={{ multus_cni_bin_dir }}"
        - "--multus-conf-file={{ multus_conf_file }}"
        - "--multus-kubeconfig-file-host={{ multus_kubeconfig_file_host }}"
        - "--namespace-isolation=false"  # <-------- here

Should I PR the project with just this flag as an option?
E.g:

- "--namespace-isolation={{ multus_namespace_isolation | default(true) | string | lower  }}"

@tico88612
Copy link
Member

Please free to open the PR if you think this will make the option flexible, but you need to follow the upstream's default value.

@tico88612
Copy link
Member

/retitle Feature request: Multus configuration add namespace isolation

@k8s-ci-robot k8s-ci-robot changed the title Multus configuration Feature request: Multus configuration add namespace isolation Oct 7, 2024
Sispheor added a commit to Sispheor/kubespray that referenced this issue Oct 7, 2024
Sispheor added a commit to Sispheor/kubespray that referenced this issue Oct 7, 2024
Sispheor added a commit to Sispheor/kubespray that referenced this issue Oct 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/feature Categorizes issue or PR as related to a new feature.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants