summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorlassulus <lassulus@lassul.us>2021-10-23 12:07:40 +0200
committerlassulus <lassulus@lassul.us>2021-10-23 12:07:40 +0200
commitc5bab88a9e2b9a30ea148e5938a2110f44f18a5e (patch)
tree9233be4b12a196b81937622f040ff435e04ef3ff
parent411cb36608f1e408b18ffff33ad30fc55775e2c3 (diff)
tinc module: add group for user
-rw-r--r--krebs/3modules/tinc.nix5
1 files changed, 5 insertions, 0 deletions
diff --git a/krebs/3modules/tinc.nix b/krebs/3modules/tinc.nix
index a8a78a43e..2c19aefdb 100644
--- a/krebs/3modules/tinc.nix
+++ b/krebs/3modules/tinc.nix
@@ -237,9 +237,14 @@ let
inherit (cfg.user) home name uid;
createHome = true;
isSystemUser = true;
+ group = netname;
}
) config.krebs.tinc;
+ users.groups = mapAttrs' (netname: cfg:
+ nameValuePair netname {}
+ ) config.krebs.tinc;
+
environment.etc = mapAttrs' (netname: cfg:
nameValuePair "tinc/${netname}" (mkIf cfg.enableLegacy {
source = cfg.confDir;