diff --git a/checks/installation-without-system/flake-module.nix b/checks/installation-without-system/flake-module.nix index cc58c8ad1..484c0671d 100644 --- a/checks/installation-without-system/flake-module.nix +++ b/checks/installation-without-system/flake-module.nix @@ -180,7 +180,7 @@ self.packages.${pkgs.system}.clan-cli ] ++ self.packages.${pkgs.system}.clan-cli.runtimeDependencies; environment.etc."install-closure".source = "${closureInfo}/store-paths"; - virtualisation.memorySize = 2048; + virtualisation.memorySize = 3048; nix.package = nixPackage; nix.settings = { substituters = lib.mkForce [ ]; diff --git a/checks/installation/flake-module.nix b/checks/installation/flake-module.nix index 311c868ca..3b996d305 100644 --- a/checks/installation/flake-module.nix +++ b/checks/installation/flake-module.nix @@ -167,7 +167,7 @@ self.packages.${pkgs.system}.clan-cli ] ++ self.packages.${pkgs.system}.clan-cli.runtimeDependencies; environment.etc."install-closure".source = "${closureInfo}/store-paths"; - virtualisation.memorySize = 2048; + virtualisation.memorySize = 3048; nix.package = nixPackage; nix.settings = { substituters = lib.mkForce [ ]; diff --git a/lib/build-clan/module.nix b/lib/build-clan/module.nix index 09cb69c3e..873ff56b5 100644 --- a/lib/build-clan/module.nix +++ b/lib/build-clan/module.nix @@ -96,12 +96,6 @@ let networking.hostName = lib.mkDefault name; - # speeds up nix commands by using the nixpkgs from the host system (especially useful in VMs) - nix.registry.nixpkgs.to = lib.mkDefault { - type = "path"; - path = lib.mkDefault nixpkgs; - }; - # For vars we need to override the system so we run vars # generators on the machine that runs `clan vars generate`. If a # users is using the `pkgsForSystem`, we don't set diff --git a/pkgs/clan-cli/tests/sshd.py b/pkgs/clan-cli/tests/sshd.py index 1b9281a34..82c9c1251 100644 --- a/pkgs/clan-cli/tests/sshd.py +++ b/pkgs/clan-cli/tests/sshd.py @@ -10,13 +10,16 @@ from tempfile import TemporaryDirectory from typing import TYPE_CHECKING import pytest -from fixture_error import FixtureError if TYPE_CHECKING: from command import Command from ports import PortFunction +class SshdError(Exception): + pass + + class Sshd: def __init__(self, port: int, proc: subprocess.Popen[str], key: str) -> None: self.port = port @@ -135,6 +138,10 @@ def sshd( extra_env=env, ) monkeypatch.delenv("SSH_AUTH_SOCK", raising=False) + + timeout = 5 + start_time = time.time() + while True: print(sshd_config.path) if ( @@ -162,5 +169,8 @@ def sshd( rc = proc.poll() if rc is not None: msg = f"sshd processes was terminated with {rc}" - raise FixtureError(msg) + raise SshdError(msg) + if time.time() - start_time > timeout: + msg = "Timeout while waiting for sshd to be ready" + raise SshdError(msg) time.sleep(0.1)