1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2024-09-11 15:08:33 +01:00

nixos/users-groups: chown home on createHome

Fixes #23619.
This commit is contained in:
Franz Pletz 2017-03-08 00:29:20 +01:00
parent e206d5ab63
commit 9ea35eae7a
No known key found for this signature in database
GPG key ID: 846FDED7792617B4

View file

@ -177,7 +177,7 @@ foreach my $u (@{$spec->{users}}) {
}
# Create a home directory.
if ($u->{createHome} && ! -e $u->{home}) {
if ($u->{createHome}) {
make_path($u->{home}, { mode => 0700 }) if ! -e $u->{home};
chown $u->{uid}, $u->{gid}, $u->{home};
}