Record source revisions and stopped containers in pipeline evidence

This commit is contained in:
Artyom
2026-11-06 09:16:57 +03:00
parent f1ecb74dc4
commit 24a51744f5
3 changed files with 13 additions and 2 deletions
+5
View File
@@ -53,6 +53,11 @@ def stop(service):
check=True,
).stdout.strip()
say(f"$ docker compose stop -t 10 {service} -> {seconds:.1f} s, exit code {code}")
say(
compose(
"ps", "-a", "--format", "{{.Name}} {{.ID}} {{.State}} {{.Status}}", service
).rstrip()
)
check(seconds <= 10 and code == "0", f"{service} did not stop cleanly on SIGTERM")
+7 -1
View File
@@ -424,7 +424,12 @@ class Suite:
steps.append({"at": now(), "step": step, **extra})
self.stack.stop(self.args.worker)
mark("worker stopped")
mark(
"worker stopped",
containers=self.stack.dc(
"ps", "-a", "--format", "{{.Name}} {{.ID}} {{.State}} {{.Status}}", self.args.worker
).splitlines(),
)
att = self.api.fixture()
mark("upload 202 queued", attachment_id=att["id"])
self.api.content(att["id"], expected=409)
@@ -904,6 +909,7 @@ class Suite:
report = {
"suite": "lab5-pipeline-idempotency",
"started_at": now(),
"source_sha": run(["git", "rev-parse", "HEAD"]).strip(),
"config": self.config(),
}
if self.args.preflight: