diff --git a/pkgs/servers/home-assistant/default.nix b/pkgs/servers/home-assistant/default.nix index a57f0d32c4a6..dc6c17f4d514 100644 --- a/pkgs/servers/home-assistant/default.nix +++ b/pkgs/servers/home-assistant/default.nix @@ -535,7 +535,7 @@ in python.pkgs.buildPythonApplication rec { ]; postPatch = '' - substituteInPlace tests/test_config.py --replace-fail '"/usr"' '"/build/media"' + substituteInPlace tests/test_config.py --replace-fail '"/usr"' "\"$NIX_BUILD_TOP/media\"" substituteInPlace pyproject.toml --replace-fail "wheel~=0.43.0" wheel @@ -665,7 +665,7 @@ in python.pkgs.buildPythonApplication rec { export HOME="$TEMPDIR" # the tests require the existance of a media dir - mkdir /build/media + mkdir "$NIX_BUILD_TOP"/media # put ping binary into PATH, e.g. for wake_on_lan tests export PATH=${inetutils}/bin:$PATH