diff --git a/flake.lock b/flake.lock index 104df3d1f..f89d6c8d3 100644 --- a/flake.lock +++ b/flake.lock @@ -7,11 +7,11 @@ ] }, "locked": { - "lastModified": 1721417620, - "narHash": "sha256-6q9b1h8fI3hXg2DG6/vrKWCeG8c5Wj2Kvv22RCgedzg=", + "lastModified": 1723080788, + "narHash": "sha256-C5LbM5VMdcolt9zHeLQ0bYMRjUL+N+AL5pK7/tVTdes=", "owner": "nix-community", "repo": "disko", - "rev": "bec6e3cde912b8acb915fecdc509eda7c973fb42", + "rev": "ffc1f95f6c28e1c6d1e587b51a2147027a3e45ed", "type": "github" }, "original": { @@ -27,11 +27,11 @@ ] }, "locked": { - "lastModified": 1719994518, - "narHash": "sha256-pQMhCCHyQGRzdfAkdJ4cIWiw+JNuWsTX7f0ZYSyz0VY=", + "lastModified": 1722555600, + "narHash": "sha256-XOQkdLafnb/p9ij77byFQjDf5m5QYl9b2REiVClC+x4=", "owner": "hercules-ci", "repo": "flake-parts", - "rev": "9227223f6d922fee3c7b190b2cc238a99527bbb7", + "rev": "8471fe90ad337a8074e957b69ca4d0089218391d", "type": "github" }, "original": { @@ -48,11 +48,11 @@ ] }, "locked": { - "lastModified": 1721571445, - "narHash": "sha256-2MnlPVcNJZ9Nbu90kFyo7+lng366gswErP4FExfrUbc=", + "lastModified": 1723079397, + "narHash": "sha256-cx5ysGbD49sSPtX660tdv6MdUrKvOu/hVvNM6xls6fE=", "owner": "nix-community", "repo": "nixos-images", - "rev": "accee005735844d57b411d9969c5d0aabc6a55f6", + "rev": "617f2cb56213d10574bc6fdb390f6e7f5b551d7e", "type": "github" }, "original": { @@ -63,11 +63,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1721571961, - "narHash": "sha256-jfF4gpRUpTBY2OxDB0FRySsgNGOiuDckEtu7YDQom3Y=", + "lastModified": 1723316219, + "narHash": "sha256-2B9qh8QBvw3kV/8cHc7ZJcrbVsRwP8wKjkwPXTSz76Y=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "4cc8b29327bed3d52b40041f810f49734298af46", + "rev": "bef98989a27429e1cb9e3d9c25701ba2da742af2", "type": "github" }, "original": { @@ -95,11 +95,11 @@ "nixpkgs-stable": [] }, "locked": { - "lastModified": 1721531171, - "narHash": "sha256-AsvPw7T0tBLb53xZGcUC3YPqlIpdxoSx56u8vPCr6gU=", + "lastModified": 1722897572, + "narHash": "sha256-3m/iyyjCdRBF8xyehf59QlckIcmShyTesymSb+N4Ap4=", "owner": "Mic92", "repo": "sops-nix", - "rev": "909e8cfb60d83321d85c8d17209d733658a21c95", + "rev": "8ae477955dfd9cbf5fa4eb82a8db8ddbb94e79d9", "type": "github" }, "original": { @@ -115,11 +115,11 @@ ] }, "locked": { - "lastModified": 1722699361, - "narHash": "sha256-3GDJCoNj7PEwQaOqmNgcwoHM+Xy/fkgqeXC1y7UzV2U=", + "lastModified": 1723656612, + "narHash": "sha256-6Sx+/VhRPLR+kRf6rnNUFMQ66DUz1DMYajixYUe+CUU=", "owner": "numtide", "repo": "treefmt-nix", - "rev": "07741a9babd0754bf73fb47a6340d6289eabd1d6", + "rev": "4a6d7dccf80a1aa2d04cfaa88d9e5511542a2486", "type": "github" }, "original": { diff --git a/formatter.nix b/formatter.nix index f9555b43b..a0786c697 100644 --- a/formatter.nix +++ b/formatter.nix @@ -56,7 +56,7 @@ "pkgs/clan-app" = { extraPythonPackages = (self'.packages.clan-app.externalTestDeps or [ ]) ++ self'.packages.clan-cli.testDependencies; - extraPythonPaths = [ "$PROJECT_ROOT/pkgs/clan-cli" ]; + extraPythonPaths = [ "../clan-cli" ]; modules = [ "clan_app" ]; }; } @@ -66,7 +66,7 @@ "pkgs/clan-vm-manager" = { extraPythonPackages = self'.packages.clan-vm-manager.externalTestDeps ++ self'.packages.clan-cli.testDependencies; - extraPythonPaths = [ "$PROJECT_ROOT/pkgs/clan-cli" ]; + extraPythonPaths = [ "../clan-cli" ]; modules = [ "clan_vm_manager" ]; }; } diff --git a/nixosModules/clanCore/vm.nix b/nixosModules/clanCore/vm.nix index cc6bc7ee0..a015f1591 100644 --- a/nixosModules/clanCore/vm.nix +++ b/nixosModules/clanCore/vm.nix @@ -45,9 +45,8 @@ let ]; boot.initrd.systemd.emergencyAccess = true; - # sysusers is faster than nixos's perl scripts - # and doesn't require state. - systemd.sysusers.enable = true; + # sysusers would be faster because it doesn't need perl, but it cannot create normal users + systemd.sysusers.enable = false; users.mutableUsers = false; users.allowNoPasswordLogin = true; diff --git a/pkgs/clan-cli/tests/fixtures_flakes.py b/pkgs/clan-cli/tests/fixtures_flakes.py index 87556468a..1ddfb444f 100644 --- a/pkgs/clan-cli/tests/fixtures_flakes.py +++ b/pkgs/clan-cli/tests/fixtures_flakes.py @@ -40,6 +40,9 @@ def substitute( line = line.replace("__CLAN_SOPS_KEY_PATH__", sops_key) line = line.replace("__CLAN_SOPS_KEY_DIR__", str(flake)) buf += line + print(f"file: {file}") + print(f"clan_core: {clan_core_flake}") + print(f"flake: {flake}") file.write_text(buf) diff --git a/pkgs/clan-cli/tests/test_history_cli.py b/pkgs/clan-cli/tests/test_history_cli.py index e65c7b2af..fd664b091 100644 --- a/pkgs/clan-cli/tests/test_history_cli.py +++ b/pkgs/clan-cli/tests/test_history_cli.py @@ -35,14 +35,12 @@ def test_history_list( capsys: CaptureFixture, test_flake_with_core: FlakeForTest, ) -> None: - cmd = [ - "history", - "list", - ] - - cli.run(cmd) + capsys.readouterr() + cli.run(["history", "list"]) assert str(test_flake_with_core.path) not in capsys.readouterr().out cli.run(["history", "add", f"clan://{test_flake_with_core.path}#vm1"]) - cli.run(cmd) + + capsys.readouterr() + cli.run(["history", "list"]) assert str(test_flake_with_core.path) in capsys.readouterr().out