Add configurable systemd service name to nixos module

This commit is contained in:
Ciaran De Groot 2023-12-17 12:36:47 -07:00
parent da2141cd93
commit 91e67df844

View file

@ -26,9 +26,14 @@ let
visible = "shallow";
};
_systemd = mkOption { internal = true; };
serviceName = mkOption {
description = "The name of the Arion project's systemd service";
type = types.str;
default = "arion-${name}";
};
};
config = {
_systemd.services."arion-${name}" = {
_systemd.services.${config.serviceName} = {
wantedBy = [ "multi-user.target" ];
after = [ "sockets.target" ];