diff options
| author | Miran Bastaja <miran.bastaja04@gmail.com> | 2024-07-06 06:48:40 +0200 |
|---|---|---|
| committer | Miran Bastaja <miran.bastaja04@gmail.com> | 2024-07-06 06:48:40 +0200 |
| commit | c97a1d66084aaf50ca816d9c482f296d31346f9f (patch) | |
| tree | d03726dfb1edfa87b93ca42b9076658c7c50c940 /share/system/virt.nix | |
| parent | fed01b401d65e655f565fc5c6304f2ab0d758513 (diff) | |
formatting
Diffstat (limited to 'share/system/virt.nix')
| -rw-r--r-- | share/system/virt.nix | 18 |
1 files changed, 13 insertions, 5 deletions
diff --git a/share/system/virt.nix b/share/system/virt.nix index 6f5a9fe..ac74332 100644 --- a/share/system/virt.nix +++ b/share/system/virt.nix @@ -1,10 +1,18 @@ -{ pkgs, virt-users ? [ ], ... }: +{ + pkgs, + virt-users ? [ ], + ... +}: let # https://stackoverflow.com/questions/75855410/nix-map-list-of-keys-to-attribute-set-members - attrSetRepeatValue = value: list: - let acc = { }; # accumulator - in builtins.foldl' (acc: key: acc // { "${key}" = value; }) acc list; -in { + attrSetRepeatValue = + value: list: + let + acc = { }; # accumulator + in + builtins.foldl' (acc: key: acc // { "${key}" = value; }) acc list; +in +{ users.users = attrSetRepeatValue { extraGroups = [ "libvirtd" ]; } virt-users; home-manager.users = attrSetRepeatValue { |
