The docker prerequisites (ca-certificates, curl) and the system_baseline packages install only from the distribution's sources, yet refreshed the APT cache on every run. They now pass cache_valid_time: 3600, the value the system_baseline update task and user_management already use, so they refresh only a cache older than an hour.
Installs from a role's own APT source (docker's Engine packages, tailscale's package) still refresh on every run. If a run wrote the source line but its refresh failed or was interrupted, the next run within the hour would otherwise see a fresh cache, skip the refresh and find no package. So tailscale, which issue #425 listed, has no change here: its only install follows its own source. The docker and tailscale update entry points are unchanged.
The apt module (ansible-core 2.19) takes the cache age from /var/lib/apt/periodic/update-success-stamp, else from the mtime of /var/lib/apt/lists.
Known risk: a source a consumer adds just before system_baseline (for example with ansible.builtin.deb822_repository, which does not refresh) is not fetched if the cache is younger than an hour; the system_baseline README now says to refresh the cache first. Likewise, on a host built from an image less than an hour before the run, an empty lists directory looks fresh. The docker and system_baseline Molecule scenarios refresh the cache in prepare.yml.
Verified
The commit hooks (pre-commit on the changed files): gitleaks, yamllint, ruff format, merge-conflict check, REUSE, antsibull-changelog-lint, ansible-lint, Conventional Commit and the Assisted-by trailer check all pass; ansible-test sanity (pre-push) passed.
ansible-playbook --syntax-check of roles/docker/molecule/default/converge.yml and roles/system_baseline/molecule/default/converge.yml.
The cache-age logic was read in the installed ansible-core 2.19.6 apt module (get_cache_mtime, lines 1172-1177; refresh check, lines 1399-1402).
Reviewed by a separate agent; its finding (an "only when the source changed" refresh would not heal a failed earlier run) is fixed by always refreshing after the role's own source.
Not verified
Molecule (runs in CI).
Behaviour on a real host with a cache older or newer than an hour.
I confirm third-party material is recorded in NOTICE and REUSE.toml, or there is none.
Assisted-by: Claude Code
## What and why
Closes #425
The docker prerequisites (`ca-certificates`, `curl`) and the system_baseline packages install only from the distribution's sources, yet refreshed the APT cache on every run. They now pass `cache_valid_time: 3600`, the value the system_baseline update task and user_management already use, so they refresh only a cache older than an hour.
Installs from a role's own APT source (docker's Engine packages, tailscale's package) still refresh on every run. If a run wrote the source line but its refresh failed or was interrupted, the next run within the hour would otherwise see a fresh cache, skip the refresh and find no package. So tailscale, which issue #425 listed, has no change here: its only install follows its own source. The docker and tailscale update entry points are unchanged.
The apt module (ansible-core 2.19) takes the cache age from `/var/lib/apt/periodic/update-success-stamp`, else from the mtime of `/var/lib/apt/lists`.
Known risk: a source a consumer adds just before system_baseline (for example with `ansible.builtin.deb822_repository`, which does not refresh) is not fetched if the cache is younger than an hour; the system_baseline README now says to refresh the cache first. Likewise, on a host built from an image less than an hour before the run, an empty lists directory looks fresh. The docker and system_baseline Molecule scenarios refresh the cache in `prepare.yml`.
## Verified
- The commit hooks (`pre-commit` on the changed files): gitleaks, yamllint, ruff format, merge-conflict check, REUSE, antsibull-changelog-lint, ansible-lint, Conventional Commit and the Assisted-by trailer check all pass; `ansible-test sanity` (pre-push) passed.
- `ansible-playbook --syntax-check` of `roles/docker/molecule/default/converge.yml` and `roles/system_baseline/molecule/default/converge.yml`.
- The cache-age logic was read in the installed ansible-core 2.19.6 apt module (`get_cache_mtime`, lines 1172-1177; refresh check, lines 1399-1402).
- Reviewed by a separate agent; its finding (an "only when the source changed" refresh would not heal a failed earlier run) is fixed by always refreshing after the role's own source.
## Not verified
- Molecule (runs in CI).
- Behaviour on a real host with a cache older or newer than an hour.
---
- [x] I confirm third-party material is recorded in `NOTICE` and `REUSE.toml`, or there is none.
Assisted-by: Claude Code
The docker prerequisites and the system_baseline packages install only
from the distribution's sources, yet refreshed the APT cache on every
run. They now pass cache_valid_time: 3600, as the system_baseline update
task and user_management already do.
The docker and tailscale installs from the role's own APT source keep
refreshing on every run, so a run that wrote the source line but failed
to fetch its lists heals on the next run. The update entry points are
unchanged.
The system_baseline README tells a consumer who adds a source just
before the role to refresh the cache themselves.
Assisted-by: Claude Code:claude-opus-5-5
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
What and why
Closes #425
The docker prerequisites (
ca-certificates,curl) and the system_baseline packages install only from the distribution's sources, yet refreshed the APT cache on every run. They now passcache_valid_time: 3600, the value the system_baseline update task and user_management already use, so they refresh only a cache older than an hour.Installs from a role's own APT source (docker's Engine packages, tailscale's package) still refresh on every run. If a run wrote the source line but its refresh failed or was interrupted, the next run within the hour would otherwise see a fresh cache, skip the refresh and find no package. So tailscale, which issue #425 listed, has no change here: its only install follows its own source. The docker and tailscale update entry points are unchanged.
The apt module (ansible-core 2.19) takes the cache age from
/var/lib/apt/periodic/update-success-stamp, else from the mtime of/var/lib/apt/lists.Known risk: a source a consumer adds just before system_baseline (for example with
ansible.builtin.deb822_repository, which does not refresh) is not fetched if the cache is younger than an hour; the system_baseline README now says to refresh the cache first. Likewise, on a host built from an image less than an hour before the run, an empty lists directory looks fresh. The docker and system_baseline Molecule scenarios refresh the cache inprepare.yml.Verified
pre-commiton the changed files): gitleaks, yamllint, ruff format, merge-conflict check, REUSE, antsibull-changelog-lint, ansible-lint, Conventional Commit and the Assisted-by trailer check all pass;ansible-test sanity(pre-push) passed.ansible-playbook --syntax-checkofroles/docker/molecule/default/converge.ymlandroles/system_baseline/molecule/default/converge.yml.get_cache_mtime, lines 1172-1177; refresh check, lines 1399-1402).Not verified
NOTICEandREUSE.toml, or there is none.Assisted-by: Claude Code