!tCyGickeVqkHsYjWnh:nixos.org

NixOS Networking

901 Members
Declaratively manage your switching, routing, wireless, tunneling and more.264 Servers

Load older messages


SenderMessageTime
28 Jul 2025
@emilazy:matrix.orgemily networkd is under systemd.network.* which is its own kind of weird :P 17:45:01
@emilazy:matrix.orgemily

well,

        message = "ifstate.nix does not currently implement a systemd unit for initrd. Please continue to use the scripted stage one for the time being.";
17:45:11
@emilazy:matrix.orgemilyso yeah we'd want to drop the initrd support for upstreaming or else implement systemd initrd support (and probably only systemd initrd support)17:45:27
@magic_rb:matrix.redalder.orgmagic_rb
In reply to @emilazy:matrix.org

well,

        message = "ifstate.nix does not currently implement a systemd unit for initrd. Please continue to use the scripted stage one for the time being.";
I dont see why it couldnt, at least v1, i havent used v2
17:45:37
@emilazy:matrix.orgemily(we are hoping to flip the default to systemd initrd within the month)17:45:38
@emilazy:matrix.orgemilyI didn't say couldn't :P I'm just talking about what the module actually says, in the context of upstreaming it17:45:52
@magic_rb:matrix.redalder.orgmagic_rb
In reply to @emilazy:matrix.org
(we are hoping to flip the default to systemd initrd within the month)
(Finally)
17:45:55
@magic_rb:matrix.redalder.orgmagic_rb
In reply to @emilazy:matrix.org
I didn't say couldn't :P I'm just talking about what the module actually says, in the context of upstreaming it
Ah okay
17:46:01
@marcel:envs.netMarcel
In reply to @emilazy:matrix.org
so yeah we'd want to drop the initrd support for upstreaming or else implement systemd initrd support (and probably only systemd initrd support)
i've just never came to create a unit, because all my sytems still use scrypted stage 1 - allthough thats something, that i will definitely add
17:47:14
@emilazy:matrix.orgemily the initrd stuff should also probably be under boot.initrd.* so you can have distinct config in initrd, that's how it works for repart and networkd though not 100% sure 17:47:25
@emilazy:matrix.orgemily(I think maybe networkd might inherit config from stage 2 or something weird like that, I forget)17:47:52
@emilazy:matrix.orgemilyI think we can also just upstream without initrd support initially FWIW, and add it later17:48:31
@elvishjerricco:matrix.orgElvishJerricco (this is something I've debated with myself a lot; we currently don't inherit configs from stage 2 for basically anything and I can't decide if that's a good thing or not. The networkd exception is that if you use boot.initrd.network.enable rather than boot.initrd.systemd.network.enable you get the networking.interfaces implementations from stage 2 basically) 17:48:45
@emilazy:matrix.orgemily(but I don't think we'll want to upstream scripted initrd support, since it's going to explicitly be on the deprecation/warning path very very soon)17:48:47
@emilazy:matrix.orgemily thankfully fixed by deprecating networking.interfaces 17:49:03
@marcel:envs.netMarcelThat's at least what I am currently doing. If you don't specify a initrd config and ifstatenis activated on initrd, it inherits the normal config17:49:10
@emilazy:matrix.orgemilyI think it's easy to inherit if you want and annoying to disable automatic inheritance if you don't17:49:17
@emilazy:matrix.orgemilyso IMO separate configs and letting people manually do explicit inheritance is the way to go17:49:27
@emilazy:matrix.orgemilyinitrd isn't the same as the booted machine17:49:37
@emilazy:matrix.orgemily (they even have different notions of machine-id by default) 17:49:42
@marcel:envs.netMarcel
In reply to @emilazy:matrix.org
I think it's easy to inherit if you want and annoying to disable automatic inheritance if you don't
Just the default, the pint you start configuring initrd stuff it is replaced and not merged
17:50:40
@marcel:envs.netMarcel If you want to merge it, you have to do it yourself as the consumer 17:51:01
@emilazy:matrix.orgemily I think that's not ideal (because if you import a module that only intends to extend the initrd network config, it unexpectedly blows away the inherited config) 17:51:15
@marcel:envs.netMarcelOk, I'll leave the default initrd config:)17:51:50
@emilazy:matrix.orgemily I think it should match boot.initrd.system.network by being separate (and in a separate hierarchy) and you can always boot.initrd.networking.ifstate = config.networking.ifstate; or such 17:51:53
@emilazy:matrix.orgemily (admittedly the boot.initrd.* hierarchy is a bit of a mess currently) 17:52:06
@marcel:envs.netMarcel
In reply to @emilazy:matrix.org
I would personally probably go for services.ifstate.* IMO, it's comparable to services.network-manager.* in that you have a systemd service managing the config, but I'm ambivalent
you are still with services.ifstate? in your last message you used networking.ifstate?
19:16:08
@emilazy:matrix.orgemily I have no consistent opinion 😅 NM is under networking.* right? 19:16:59
@emilazy:matrix.orgemilyI'd match NM19:17:01
@marcel:envs.netMarcelyeah19:17:21

Show newer messages


Back to Room ListRoom Version: 6