The sweep now fails the step when a timestamp cannot be parsed or a
container it removes is still there, while tolerating one another run's
sweep removed first. Its 30-minute bound and the job's timeout point at
each other, since a shorter bound would remove a live run's containers.
The concurrency comments of Lint and Build now say that runs on one ref
queue rather than cancel, and the scenarios' comment names the run
script as what removes their containers. The workflow test checks the
label filters of the sweep and cleanup steps by name.
Assisted-by: Claude Code:claude-opus-5-5
Two Molecule runs could not overlap on one Docker daemon because every
scenario's container name was fixed; only the runner's single slot kept
them apart. Each platform is now named and labelled by KAMINO_RUN_ID
(run id and attempt, "local" outside CI), the run script expands those
names with molecule's own interpolator before removing them, and the
workflow removes its own containers by label and only sweeps labelled
leftovers older than the job timeout, so a run still going is never hit.
Non-pull-request runs get a concurrency group of their own.
Push to main no longer triggers Molecule, Lint or Build: a merged pull
request was already tested, and the nightly and manual Molecule runs
cover every scenario. Build keeps its v* tag trigger.
Assisted-by: Claude Code:claude-opus-5-5
Pin molecule and its Docker driver in requirements-dev.txt and bake them,
with the driver's collection, into the ci image. The Molecule job runs
docker run on the pinned ci image with the Docker socket and the checkout
mounted at the same path, as the runner user. A pull request whose pins
differ from the image installs its own pins first, so a core bump runs its
scenarios on the new core. gitea_runner no longer installs the molecule
venv and collections.
Closes#225
Assisted-by: Claude Code
molecule's trailing destroy runs the Docker driver's destroy playbook, whose
"Wait for instance(s) deletion to complete" task alone costs about 5.6 s per
scenario, about 84 s over the 15 scenarios of a full run. The whole destroy
phase measured about 103 s per full run (the median across full runs, among
them 4764, 4714, 4698 and 4578). The workflow already removes stale
containers before the run, so it can remove each scenario's containers itself
with `docker rm -f` as soon as the scenario ends, pass or fail, and skip the
playbook.
The names come from each scenario's molecule.yml (platforms[].name) via the
molecule venv's Python and PyYAML, so no list is kept in the workflow. A
failed removal fails the step. The test_sequence rule in the workflow guidance
now says both destroys are left out and that platform names are literal.
Assisted-by: Claude Code:claude-opus-5-5
Every scenario failed in its create step (couldn't resolve module community.docker.docker_login): molecule's Docker driver runs community.docker modules in its own create and destroy playbooks, and the collection came from the runner-provisioned /opt/molecule-collections that the previous commit stopped reading. The roles do not call it, so it is not in requirements.yml, which the ci image bakes for Lint and which Renovate would rebuild the image for. It is pinned in extensions/molecule/requirements.yml instead; the Molecule job installs both files, cached by their combined checksum. Renovate tracks the new file and the bot-diff gate allows only its version: lines.
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_014uGZTNmHMc85bomfevwUDG
Moves the MOLECULE_IMAGE pin to 0.1.6, the build of #119 that carries gnupg, and
with it:
- removes the gnupg install (and its apt update) from the docker scenario's
prepare, about 10 s of its 12 s; the role refreshes its own apt cache at
install, so nothing relied on that update;
- adds gnupg to the image-smoke contract, so the image keeps providing it;
- drops gnupg from the docker README's list of what the scenario needs the
Ubuntu mirrors for, with a trivial changelog fragment.
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_014uGZTNmHMc85bomfevwUDG
The first destroy runs against a container that is not there and only waits out
the Docker driver's fixed 5 s poll, about 6 s per scenario and 42 s per full
run. The run step already removes what a killed run left, and molecule's state
file lives under the job's own ANSIBLE_HOME (Runtime(isolated=False)), which is
deleted with the checkout, so a cancelled run cannot make the next one skip
create or prepare. The rest of the sequence is molecule's default.
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_014uGZTNmHMc85bomfevwUDG
Adds the image-smoke-2604 scenario (asserts Ubuntu 26.04) and the MOLECULE_IMAGE_2604 pin
(molecule-ubuntu2604 0.1.0, the digest its first build printed, run 2534). Moves
MOLECULE_IMAGE to molecule-ubuntu2404 0.1.2 (digest printed by run 2541): the 0.1.1 image
is Ubuntu 26.04, so image-smoke has failed on main since the base bump. The Renovate
pattern for the multi-line pin now also reads MOLECULE_IMAGE_<release>.
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01MmzvM9skAvYcph2c9EiPcm
ansible-lint name[casing] on the smoke verify task; and the workflow trigger
paths are written out for both events (YAML anchors in an `on:` block are not
something to rely on in Gitea's workflow parser).
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01MmzvM9skAvYcph2c9EiPcm
.gitea/workflows/molecule.yml runs every molecule scenario of the Collection
on the kamino-molecule host-executor label of kamino-runner (the Docker
daemon of the runner LXC, no job container, no Docker socket handed out),
against the molecule-ubuntu2404 image pinned by tag and digest. Scenarios are
discovered: extensions/molecule/*/ and roles/*/molecule/*/, so the wave-1 roles
only add their scenario directory.
extensions/molecule/image-smoke tests the image itself: Ubuntu 24.04, systemd
as PID 1 and reachable over the container connection, the packages the roles
manage, ssh enabled, the python bindings Ansible needs, NET_ADMIN. A rebuilt
or re-pinned image therefore has to pass before a role scenario trusts it.
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01MmzvM9skAvYcph2c9EiPcm