diff options
author | ene <ene@sils.li> | 2023-02-21 17:44:49 +0100 |
---|---|---|
committer | ene <ene@sils.li> | 2023-02-21 17:44:49 +0100 |
commit | 596975a9cb1a7b9ea47cb7c065c2ed7bc02f9186 (patch) | |
tree | 2df5efdcedcb154b09f758d771ca1f742caec77e | |
parent | Fix(user): Add a real module and change passwords (diff) | |
download | nixos-config-596975a9cb1a7b9ea47cb7c065c2ed7bc02f9186.tar.gz nixos-config-596975a9cb1a7b9ea47cb7c065c2ed7bc02f9186.zip |
Fix(home): permissions (hopefully)
Diffstat (limited to '')
-rw-r--r-- | system/users/default.nix | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/system/users/default.nix b/system/users/default.nix index 116a96be..8efece26 100644 --- a/system/users/default.nix +++ b/system/users/default.nix @@ -8,7 +8,7 @@ cfg = config.soispha.users; in { options.soispha.users = { -# enable = lib.mkEnableOption (lib.mdDoc "users"); + # enable = lib.mkEnableOption (lib.mdDoc "users"); hashedPassword = lib.mkOption { type = lib.types.str; example = lib.literalExpression "$y$jFT$ONrCqZIJKB7engmfA4orD/$0GO58/wV5wrYWj0cyONhyujZPjFmbT0XKtx2AvXLG0B"; @@ -29,5 +29,12 @@ in { uid = 1000; }; }; + system.activationScripts.home_permissions = + pkgs.lib.stringAfter ["users"] + '' + mkdir /home/soispha + chmod 700 /home/soispha + chown -hR soispha:users /home/soispha + ''; }; } |