nixos-install: Create /root/.nix-defexpr

This was previously done by nixos-prepare-root.
This commit is contained in:
Eelco Dolstra 2018-02-27 20:21:23 +01:00
parent b14d9e1568
commit 84f93dd07a
No known key found for this signature in database
GPG Key ID: 8170B4726D7198DE

View File

@ -115,6 +115,8 @@ if [[ -z $noChannelCopy ]]; then
mkdir -p $mountPoint/nix/var/nix/profiles/per-user/root
nix-env --store "$mountPoint" "${extraBuildFlags[@]}" --extra-substituters "$sub" \
-p $mountPoint/nix/var/nix/profiles/per-user/root/channels --set "$channelPath" --quiet
install -m 0700 -d $mountPoint/root/.nix-defexpr
ln -sfn /nix/var/nix/profiles/per-user/root/channels $mountPoint/root/.nix-defexpr/channels
fi
fi