Fix bugs related to mismatched / missing nix
This commit is contained in:
parent
543c5fd968
commit
25dd48b795
@ -239,6 +239,12 @@ in
|
||||
packages = with pkgs; [
|
||||
pkgs'.mine.nix
|
||||
];
|
||||
|
||||
# Without this, we are at the mercy of whatever version of nix is in $PATH...
|
||||
# TODO: Is this the right thing to do?
|
||||
extraActivationPath = [
|
||||
config.nix.package
|
||||
];
|
||||
};
|
||||
})
|
||||
(mkIf pkgs.stdenv.isLinux (mkMerge [
|
||||
@ -272,7 +278,7 @@ in
|
||||
# No targets.genericLinux equivalent apparently
|
||||
sessionVariablesExtra =
|
||||
''
|
||||
. "${pkgs.nix}/etc/profile.d/nix.sh"
|
||||
. "${config.nix.package}/etc/profile.d/nix.sh"
|
||||
'';
|
||||
packages = with pkgs; [
|
||||
cacert
|
||||
|
@ -198,7 +198,7 @@ in
|
||||
''
|
||||
if [ ! -e "${sysProfile}" ]; then
|
||||
echo "Creating dummy profile"
|
||||
${pkgs.nix}/bin/nix-env -p ${sysProfile} --set ${dummyProfile}
|
||||
${config.nix.package}/bin/nix-env -p ${sysProfile} --set ${dummyProfile}
|
||||
fi
|
||||
''}
|
||||
|
||||
|
@ -9,7 +9,7 @@ let
|
||||
keepGensOpt = with lib.types; mkOpt' ints.unsigned 10
|
||||
"Number of generations to keep when cleaning up old deployments (0 to disable deletion on deployment).";
|
||||
keepGensSnippet = p: n: optionalString (n > 0) ''
|
||||
${pkgs.nix}/bin/nix-env -p "${p}" --delete-generations +${toString n}
|
||||
${config.nix.package}/bin/nix-env -p "${p}" --delete-generations +${toString n}
|
||||
'';
|
||||
|
||||
# Based on https://github.com/serokell/deploy-rs/blob/master/flake.nix
|
||||
|
Loading…
Reference in New Issue
Block a user