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 set a custom subnet range for the nerdctl bridge IP which is currently set to 10.4.0.0/24. In docker, this can be done by setting the bip option in daemon config, however I could not find a similar option in nerdctl. A quick and hacky way to get around this is to manually update the bridge cni conf file to set the subnet and gateway, however I would like to discuss if this can be added as a option in nerdctl toml.
Also, unlike docker, nerdctl does not allow removing the default bridge network, so we will need some additional handling to detect the change of bridge ip (in case the option gets added after the bridge is already created), and trigger a update workflow. I have a reference implementation here here.
Is this something the community would consider to add as a new feature? If so I can go ahead and open a PR.
Describe the solution you'd like
Introduce a new option in nerdctl.toml
| `bridge_ip` | `--bridge-ip` | `NERDCTL_BRIDGE_IP` | IP address for the default nerdctl bridge network
That configures the default 'bridge' network with the specified ip address. If the bridge network is already created, adding this new option will update the existing 'bridge' IP provided there are no running containers attached to that network.
Additional context
No response
The text was updated successfully, but these errors were encountered:
My usecase is using finch with nerdctl. finch relies on the default bridge network that nerdctl creates. So containers launched without any network --network get attached to this default network.
Creating a new bridge network does not work, since the default network has special treatment in nerdctl which we would like to preserve, such as protection again network prune commands.
What is the problem you're trying to solve
I would like to set a custom subnet range for the nerdctl bridge IP which is currently set to 10.4.0.0/24. In docker, this can be done by setting the
bip
option in daemon config, however I could not find a similar option in nerdctl. A quick and hacky way to get around this is to manually update the bridge cni conf file to set the subnet and gateway, however I would like to discuss if this can be added as a option in nerdctl toml.Also, unlike docker, nerdctl does not allow removing the default bridge network, so we will need some additional handling to detect the change of bridge ip (in case the option gets added after the bridge is already created), and trigger a update workflow. I have a reference implementation here here.
Is this something the community would consider to add as a new feature? If so I can go ahead and open a PR.
Describe the solution you'd like
Introduce a new option in nerdctl.toml
That configures the default 'bridge' network with the specified ip address. If the bridge network is already created, adding this new option will update the existing 'bridge' IP provided there are no running containers attached to that network.
Additional context
No response
The text was updated successfully, but these errors were encountered: