From 55344df0893d008c709ae7036df5145df857ce0a Mon Sep 17 00:00:00 2001 From: Michal Rus Date: Sun, 5 Nov 2017 17:51:18 +0100 Subject: [PATCH] users-groups module: use `buildEnv` in per-user profiles Resolves #31253 --- nixos/modules/config/users-groups.nix | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/nixos/modules/config/users-groups.nix b/nixos/modules/config/users-groups.nix index a4715175cc95..c1102d558101 100644 --- a/nixos/modules/config/users-groups.nix +++ b/nixos/modules/config/users-groups.nix @@ -582,13 +582,15 @@ in { { environment = { etc = mapAttrs' (name: { packages, ... }: { - name = "per-user-pkgs/${name}"; - value.source = pkgs.symlinkJoin { - name = "per-user-pkgs.${name}"; + name = "profiles/per-user/${name}"; + value.source = pkgs.buildEnv { + name = "user-environment"; paths = packages; + inherit (config.environment) pathsToLink extraOutputsToInstall; + inherit (config.system.path) ignoreCollisions postBuild; }; }) (filterAttrs (_: { packages, ... }: packages != []) cfg.users); - profiles = ["/etc/per-user-pkgs/$LOGNAME"]; + profiles = ["/etc/profiles/per-user/$USER"]; }; } ];