You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I would like to move multiple network interfaces into a container network namespace using the plugin host-device. The default interface name (eth0) is used for both. It fails because duplicated interface name isn't allowed.
Attempted Solutions
I tried setting the environment variable CNI_IFNAME when starting nomad client, but it didn't work.
The text was updated successfully, but these errors were encountered:
Hi @nakabonne and thanks for raising this issue. It's an interesting one as the specification states that it must be passed via an environment variable to the CNI plugin called when building the network namespace. This would explain why it doesn't work when setting the env var on the Nomad agent process.
I'll mark this enhancement as needing investigation, as there are a number of UX factors to consider along with what CNI plugins truly support this.
Ref https://discuss.hashicorp.com/t/does-nomad-provide-the-ability-to-set-cni-parameters/40996
Proposal
It would be nice if we could set CNI_IFNAME as a parameter when inserting network interface into container using CNI plugin.
As far as I can tell from the source code, seems like it doesn’t accept any parameters (args):
https://github.com/hashicorp/nomad/blob/f233f7446cce12fc82e823165705ad8e4ad9d0db/client/allocrunner/networking_cni.go/#L100
Use-cases
I would like to move multiple network interfaces into a container network namespace using the plugin host-device. The default interface name (eth0) is used for both. It fails because duplicated interface name isn't allowed.
Attempted Solutions
I tried setting the environment variable
CNI_IFNAME
when starting nomad client, but it didn't work.The text was updated successfully, but these errors were encountered: