[Nix-dev] Is systemd a benefit or a liability?

Eelco Dolstra eelco.dolstra at logicblox.com
Sun Oct 19 15:09:15 CEST 2014


Hi,

On 19/10/14 13:30, Nathan Bijnens wrote:

> It's not all quiet at other Distro's, some Debian developers are considering
> forking Debian if Debian switches to SystemD: http://debianfork.org/
> 
> I like some of the features of SystemD; on the other hand it makes porting Nix
> very hard to Non-linux. 

To be clear: Nix has no dependency whatsoever on systemd. NixOS obviously does,
but since it's a Linux distribution, it doesn't have to be portable to non-Linux
systems.

> I think it makes sense to have a abstraction in Nix for defining services and
> timers; by default it uses SystemD, but it shouldn't be to hard to have other
> implementations (like plain cron, ...). This would make Nix(OS) as future proof
> as possible. 

Defining services in an abstract way sounds nice. NixOS had a "jobs" option that
was intended to do just that. Unfortunately, it's not really achievable because
the semantics of the init system always leak through (e.g. Upstart's dependency
model is totally different from systemd's). Worse, you would have to restrict
yourself to the lowest common denominator of all init systems. So no socket
activation, startup notification (like sd_notify), automatic cleanup of dangling
processes via cgroups, and so on.

-- 
Eelco Dolstra | LogicBlox, Inc. | http://nixos.org/~eelco/


More information about the nix-dev mailing list