Open bjornfor opened 2 days ago
Ping @SuperSandro2000 due to https://github.com/NixOS/nixpkgs/commit/ec00b4bb1186719bbee30a89ca7f519c30001abd ("nixos/network-interfaces-scripted: remove network-setup unit if unused").
The conditions where based on the content of scripts at the time. If enabling resolvconf alone shouldn't create the unit, feel free to pr it. I don't have anything to test it against, i just dropped the unit from my system which I shouldn't have had based on my config.
Describe the bug
network-setup.service is disabled when resolvconf is disabled:
https://github.com/NixOS/nixpkgs/blob/bb8c2cf7ea0dd2e18a52746b2c3a5b0c73b93c22/nixos/modules/tasks/network-interfaces-scripted.nix#L87-L94
And enabling systemd-resolved disables resolvconf. And without network-setup.service, VLAN interfaces (and presumably bridges, MACVLANs and all the other stuff) will not be brought up.
Steps To Reproduce
networking.vlans = ...
andservices.resolved.enable = true
.Expected behavior
Enabling systemd-resolved should not break VLAN interfaces.
Additional context
The code to disable network-setup.service based on resolvconf comes from ec00b4bb1186719bbee30a89ca7f519c30001abd ("nixos/network-interfaces-scripted: remove network-setup unit if unused"). Doesn't that sound like an optimisation rather than a fix? Can we just drop
config.networking.resolvconf.enable
from the condition?Notify maintainers
Metadata
NixOS 24.05.
Add a :+1: reaction to issues you find important.