nixos/systemd/repart: add Varlink socket

This enables the ability to use systemd-repart over Varlink at
/run/systemd/io.systemd.Repart.

Change-Id: Ia74fdf8c2cbc4ec52994ba8ceb5796acc731abd3
Signed-off-by: Raito Bezarius <masterancpp@gmail.com>
This commit is contained in:
Raito Bezarius
2026-06-25 09:50:38 +02:00
parent 8a6f1ef744
commit 1fc433dc51
3 changed files with 12 additions and 0 deletions
+5
View File
@@ -209,6 +209,11 @@ let
"dbus-org.freedesktop.portable1.service"
"systemd-portabled.service"
]
++ optionals cfg.package.withRepart [
# Varlink APIs
"systemd-repart@.service"
"systemd-repart.socket"
]
++ [
"systemd-exit.service"
"systemd-update-done.service"
@@ -157,6 +157,12 @@ in
boot.initrd.systemd = lib.mkIf initrdCfg.enable {
additionalUpstreamUnits = [
"systemd-repart.service"
# Varlink APIs
# NOTE: compared to stage 2 where the IPC is enabled in the global location, initrd
# might be optimized to keep away the repart binary.
# As a result, we enable repart IPC in the initrd only if repart is enabled in the initrd.
"systemd-repart.socket"
"systemd-repart@.service"
];
storePaths = [
@@ -703,6 +703,7 @@ stdenv.mkDerivation (finalAttrs: {
withMachined
withNetworkd
withNspawn
withRepart
withPortabled
withSysupdate
withTimedated