mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-07-14 06:00:33 +03:00
nixos-rebuild-ng: set TMPDIR in darwin
This commit is contained in:
parent
063639b2be
commit
1d3c452d63
1 changed files with 8 additions and 0 deletions
|
@ -1,5 +1,6 @@
|
|||
{
|
||||
lib,
|
||||
stdenv,
|
||||
callPackage,
|
||||
installShellFiles,
|
||||
mkShell,
|
||||
|
@ -12,6 +13,9 @@
|
|||
withNgSuffix ? true,
|
||||
withReexec ? false,
|
||||
withShellFiles ? true,
|
||||
# Very long tmp dirs lead to "too long for Unix domain socket"
|
||||
# SSH ControlPath errors. Especially macOS sets long TMPDIR paths.
|
||||
withTmpdir ? if stdenv.hostPlatform.isDarwin then "/tmp" else null,
|
||||
}:
|
||||
let
|
||||
executable = if withNgSuffix then "nixos-rebuild-ng" else "nixos-rebuild";
|
||||
|
@ -73,6 +77,10 @@ python3Packages.buildPythonApplication rec {
|
|||
|
||||
pytestFlagsArray = [ "-vv" ];
|
||||
|
||||
makeWrapperArgs = lib.optionals (withTmpdir != null) [
|
||||
"--set TMPDIR ${withTmpdir}"
|
||||
];
|
||||
|
||||
passthru =
|
||||
let
|
||||
python-with-pkgs = python3.withPackages (
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue