nixos-rebuild-ng: add missing FLAKE_FLAGS in nix eval calls
This commit is contained in:
@@ -314,6 +314,7 @@ def get_build_image_name_flake(
|
||||
r = run_wrapper(
|
||||
[
|
||||
"nix",
|
||||
*FLAKE_FLAGS,
|
||||
"eval",
|
||||
"--json",
|
||||
flake.to_attr(
|
||||
@@ -365,6 +366,7 @@ def get_build_image_variants_flake(
|
||||
r = run_wrapper(
|
||||
[
|
||||
"nix",
|
||||
*FLAKE_FLAGS,
|
||||
"eval",
|
||||
"--json",
|
||||
flake.to_attr("config.system.build.images"),
|
||||
|
||||
@@ -386,6 +386,8 @@ def test_execute_nix_build_image_flake(mock_run: Mock, tmp_path: Path) -> None:
|
||||
call(
|
||||
[
|
||||
"nix",
|
||||
"--extra-experimental-features",
|
||||
"nix-command flakes",
|
||||
"eval",
|
||||
"--json",
|
||||
'/path/to/config#nixosConfigurations."hostname".config.system.build.images',
|
||||
@@ -412,6 +414,8 @@ def test_execute_nix_build_image_flake(mock_run: Mock, tmp_path: Path) -> None:
|
||||
call(
|
||||
[
|
||||
"nix",
|
||||
"--extra-experimental-features",
|
||||
"nix-command flakes",
|
||||
"eval",
|
||||
"--json",
|
||||
'/path/to/config#nixosConfigurations."hostname".config.system.build.images.azure.passthru.filePath',
|
||||
|
||||
@@ -394,6 +394,8 @@ def test_get_build_image_variants_flake(mock_run: Mock) -> None:
|
||||
mock_run.assert_called_with(
|
||||
[
|
||||
"nix",
|
||||
"--extra-experimental-features",
|
||||
"nix-command flakes",
|
||||
"eval",
|
||||
"--json",
|
||||
"/flake.nix#myAttr.config.system.build.images",
|
||||
|
||||
Reference in New Issue
Block a user