NixOS / nixpkgs

Nix Packages collection & NixOS
MIT License
17.39k stars 13.61k forks source link

Tracking issue: add systemd slices for related services #279915

Open h7x4 opened 8 months ago

h7x4 commented 8 months ago

Issue description

I'd like to start organizing some of the nixos services into systemd slices.

According to the systemd.slice docs, A slice unit is a concept for hierarchically managing resources of a group of processes. There are quite a few modules that split up their services into several systemd units, which I think makes sense to collect into a slice.

Some of the benefits of creating such slices would be:

As a side note, I also think most slices should be prefixed with system- if there's not a good reason not to. By default, service and scope units are placed in system.slice. This would be in contrast to something like how php-fpm is currently put in a top-level slice (planning to move this as part of this tracking issue).

TODO

tomodachi94 commented 3 weeks ago

Upstream PR filed at https://github.com/OpenPrinting/cups/pull/1035 to add a slice for the CUPS printing system, since it appears we use the upstream units.