nixos/harmonia: allocate user

DynamicUser seem to broken in combination with the nix-daemon.
This commit is contained in:
Jörg Thalheim 2023-12-03 17:07:48 +01:00 committed by Jörg Thalheim
parent 625d82720e
commit bd88398369

View file

@ -29,6 +29,11 @@ in
config = lib.mkIf cfg.enable {
nix.settings.extra-allowed-users = [ "harmonia" ];
users.users.harmonia = {
isSystemUser = true;
group = "harmonia";
};
users.groups.harmonia = { };
systemd.services.harmonia = {
description = "harmonia binary cache service";
@ -50,7 +55,6 @@ in
ExecStart = lib.getExe cfg.package;
User = "harmonia";
Group = "harmonia";
DynamicUser = true;
PrivateUsers = true;
DeviceAllow = [ "" ];
UMask = "0066";