vm-tests: the state gate refuses an empty volume until the marker is written
This commit is contained in:
parent
a4015fd03a
commit
b95d5feb26
1 changed files with 164 additions and 69 deletions
|
|
@ -181,9 +181,13 @@ pkgs.testers.runNixOSTest {
|
|||
};
|
||||
system.stateVersion = "25.11";
|
||||
|
||||
specialisation.k8s.configuration.services.hyperhive.deploy.swarm-controller.runtime = "k8s";
|
||||
specialisation.k8s.configuration.services.hyperhive.deploy.swarm-controller = {
|
||||
runtime = "k8s";
|
||||
k8s.freshState = true;
|
||||
};
|
||||
specialisation.k8s-rev.configuration.services.hyperhive.deploy = {
|
||||
swarm-controller.runtime = "k8s";
|
||||
swarm-controller.k8s.freshState = true;
|
||||
hive-controller.hyperhiveRev = lib.mkForce revB;
|
||||
};
|
||||
|
||||
|
|
@ -390,7 +394,7 @@ pkgs.testers.runNixOSTest {
|
|||
except Exception:
|
||||
diagnose(["hyperhive-k8s-ca-trust.service"])
|
||||
print(machine.execute(f"kubectl -n {NS} describe pod {name}")[1])
|
||||
for container in ("tls-issue", "tls-renew", SERVICE):
|
||||
for container in ("state-gate", "tls-issue", "tls-renew", SERVICE):
|
||||
print(machine.execute(f"kubectl -n {NS} logs {name} -c {container} --tail=60")[1])
|
||||
raise
|
||||
return name
|
||||
|
|
@ -524,7 +528,7 @@ pkgs.testers.runNixOSTest {
|
|||
assert probe["path"] == "/readyz", probe
|
||||
api = next(p for p in main["ports"] if p["name"] == "api")
|
||||
assert api["hostPort"] == PORT and api["hostIP"] == NODE_ADDRESS, api
|
||||
assert [c["name"] for c in spec["initContainers"]] == ["tls-issue"], spec["initContainers"]
|
||||
assert [c["name"] for c in spec["initContainers"]] == ["state-gate", "tls-issue"], spec["initContainers"]
|
||||
assert "tls-renew" in [c["name"] for c in spec["containers"]]
|
||||
assert not any("secret" in v for v in spec["volumes"]), spec["volumes"]
|
||||
env = {e["name"]: e.get("value") for e in main["env"]}
|
||||
|
|
|
|||
Loading…
Reference in a new issue