G5: Add CI to the most critical Ansible roles #53

Open
opened 2026-11-09 17:06:02 +00:00 by claude · 2 comments
Member

Add the reusable lint workflow to: ansible-role-gitea (replacing demo.yaml), ansible-role-eom, ansible-role-www, ansible-role-dex, ansible-role-discourse, ansible-role-mcp-servers, ansible-role-prometheus, ansible-role-listmonk.

Acceptance: each role has a passing workflow or a baseline of known issues. Link the runs here.

Depends on: G2.

Add the reusable lint workflow to: ansible-role-gitea (replacing `demo.yaml`), ansible-role-eom, ansible-role-www, ansible-role-dex, ansible-role-discourse, ansible-role-mcp-servers, ansible-role-prometheus, ansible-role-listmonk. **Acceptance**: each role has a passing workflow or a baseline of known issues. Link the runs here. Depends on: G2.
claude added this to the CI/CD 2: Quality gates milestone 2026-11-09 17:06:02 +00:00
claude added the
priority
high
cicd
labels 2026-11-09 17:06:02 +00:00
claude added this to the CI/CD Roadmap project 2026-11-09 17:07:33 +00:00
Author
Member

First batch prepared (3 of 8 roles): committed and tested locally, not yet run on the runner.

What's committed

  • Reusable workflow (8efe539): reusable-ansible-role-lint.yaml now passes --exclude .gitea. Without it, ansible-lint flagged the callers' own workflow files (yaml[truthy] on on:), and actionlint already checks those. The documented baseline command matches. docs/ci-cd/adding-ci.md now notes that .ansible-lint-ignore works per file and rule, not per line. A new finding of a rule that's already baselined in the same file only warns. New rules, and findings in new files, fail.
  • In each role, .gitea/workflows/lint.yaml (manual-only until S8 and G1, with the push/PR trigger in the header, concurrency and contents: read) plus a generated .ansible-lint-ignore:
    Role Commit Existing findings baselined Baseline lines
    ansible-role-gitea DevOps/ansible-role-gitea@e7cd36c 48 21
    ansible-role-www DevOps/ansible-role-www@b4cf39d 24 12
    ansible-role-dex DevOps/ansible-role-dex@3d540d0 5 4
  • Submodules bumped in 482ad09. These are CI files only, so what the roles deploy doesn't change.
  • demo.yaml in ansible-role-gitea is kept for now. It's the role's only on-push smoke test. The new lint.yaml header says to delete it when the trigger switches to push. It ran once on this push, as it does on every push (run 20161). The new workflows started no runs.

Tested on the workstation. I extracted the reusable workflow's run: step and ran it in python:3.13.18-slim-trixie with the G1 image's pinned requirements.txt (ansible-lint 26.11.0, ansible-core 2.21.6):

Case gitea www dex
As is fails (48) fails (24) fails (5)
With the baseline passes, all as warnings passes passes
Plus a planted shell: task fails (4 new) fails (8 new) fails (8 new)

actionlint 1.7.12 passes on the callers and the reusable workflow.

Gap to fix later: dex's baseline includes syntax-check[specific] for playbooks/deploy-eom.yml. That playbook names the role by a roles/ericomeehan.dex path, which doesn't resolve inside the role repo, so the playbook isn't syntax-checked anywhere yet. G3 (#51) covers only software-infrastructure's own top-level playbooks. To fix it, either refer to the role by name (ericomeehan.dex) or lint that playbook from software-infrastructure.

Not tested: a run on the runner, or the cross-repo uses:.

Remaining

  1. Next batch: ansible-role-eom, ansible-role-discourse, ansible-role-mcp-servers, ansible-role-prometheus, ansible-role-listmonk.
  2. After S8 (#41) and G1 (#49): switch triggers, run each once, link the runs here, and delete demo.yaml.

— eom-cicd-roadmap

**First batch prepared (3 of 8 roles): committed and tested locally, not yet run on the runner.** **What's committed** - **Reusable workflow** (8efe539): `reusable-ansible-role-lint.yaml` now passes `--exclude .gitea`. Without it, ansible-lint flagged the callers' own workflow files (`yaml[truthy]` on `on:`), and actionlint already checks those. The documented baseline command matches. `docs/ci-cd/adding-ci.md` now notes that `.ansible-lint-ignore` works per file and rule, not per line. A new finding of a rule that's already baselined in the same file only warns. New rules, and findings in new files, fail. - In each role, `.gitea/workflows/lint.yaml` (manual-only until S8 and G1, with the push/PR trigger in the header, `concurrency` and `contents: read`) plus a generated `.ansible-lint-ignore`: | Role | Commit | Existing findings baselined | Baseline lines | |---|---|---|---| | ansible-role-gitea | DevOps/ansible-role-gitea@e7cd36c | 48 | 21 | | ansible-role-www | DevOps/ansible-role-www@b4cf39d | 24 | 12 | | ansible-role-dex | DevOps/ansible-role-dex@3d540d0 | 5 | 4 | - Submodules bumped in 482ad09. These are CI files only, so what the roles deploy doesn't change. - **`demo.yaml` in ansible-role-gitea is kept for now.** It's the role's only on-push smoke test. The new `lint.yaml` header says to delete it when the trigger switches to push. It ran once on this push, as it does on every push (run 20161). The new workflows started no runs. **Tested on the workstation.** I extracted the reusable workflow's `run:` step and ran it in `python:3.13.18-slim-trixie` with the G1 image's pinned `requirements.txt` (ansible-lint 26.11.0, ansible-core 2.21.6): | Case | gitea | www | dex | |---|---|---|---| | As is | fails (48) | fails (24) | fails (5) | | With the baseline | passes, all as warnings | passes | passes | | Plus a planted `shell:` task | fails (4 new) | fails (8 new) | fails (8 new) | `actionlint` 1.7.12 passes on the callers and the reusable workflow. **Gap to fix later:** dex's baseline includes `syntax-check[specific]` for `playbooks/deploy-eom.yml`. That playbook names the role by a `roles/ericomeehan.dex` path, which doesn't resolve inside the role repo, so the playbook isn't syntax-checked anywhere yet. G3 (#51) covers only `software-infrastructure`'s own top-level playbooks. To fix it, either refer to the role by name (`ericomeehan.dex`) or lint that playbook from `software-infrastructure`. **Not tested:** a run on the runner, or the cross-repo `uses:`. **Remaining** 1. Next batch: ansible-role-eom, ansible-role-discourse, ansible-role-mcp-servers, ansible-role-prometheus, ansible-role-listmonk. 2. After S8 (#41) and G1 (#49): switch triggers, run each once, link the runs here, and delete `demo.yaml`. — eom-cicd-roadmap
Author
Member

Second batch prepared: all 8 roles now have a caller and a baseline. Committed and tested locally, not yet run on the runner.

What's committed

  • Reusable workflow (69e12d2): the role-lint step now also links the role's bare name (eom) as well as the repo name (ansible-role-eom). ansible-role-eom's skeleton tests/test.yml uses the bare name, so syntax-check failed, and that rule can't be baselined. The documented baseline command in docs/ci-cd/adding-ci.md has the same link, and the test table has today's results.
  • In each role, .gitea/workflows/lint.yaml (same manual-only caller as batch 1, push/PR trigger in its header) plus a generated .ansible-lint-ignore:
    Role Commit Baseline entries (file + rule)
    ansible-role-eom DevOps/ansible-role-eom@73fd990 99
    ansible-role-discourse DevOps/ansible-role-discourse@04321c8 1
    ansible-role-mcp-servers DevOps/ansible-role-mcp-servers@e4923a6 7
    ansible-role-listmonk DevOps/ansible-role-listmonk@81ffa27 2
    ansible-role-prometheus DevOps/ansible-role-prometheus@197921d 12
  • Submodules for eom, listmonk, mcp-servers and prometheus bumped in 13ca806. ansible-role-discourse isn't a submodule of this repo. CI files only, so nothing the roles deploy changes. None of these pushes started a run; I checked the Actions run lists.

Tested on the workstation, by running the reusable workflow's run: step verbatim (extracted from the YAML) in a local build of the tools image 1.0.0, with REPO set as the job would set it:

Case Result
eom, discourse, mcp-servers, listmonk, prometheus with their baselines all pass
gitea, www, dex (batch 1) with the changed step still pass
listmonk plus a new tasks/extra.yml with an unnamed shell: task fails, on the new file only
eom with the previous step (no bare-name link) fails in syntax-check

actionlint passes on the changed reusable workflow and all five callers.

Noted while baselining: ansible-role-eom's tasks/matrix.yaml sets the ingress host key twice with the same value, so it's harmless. It's in the baseline as yaml[key-duplicates]. That file also doesn't seem to be included from tasks/main.yaml; worth checking whether it's dead before anyone fixes it.

Why it stays open: the acceptance asks for links to passing runs. That needs the runner fixes live and S8 (#41) to pass, then G1 (#49) to publish the tools image. When that happens: switch the eight callers to push/PR (in batches, per the shared-runner rule), delete ansible-role-gitea's demo.yaml, link the runs here, and close.

— eom-cicd-roadmap

**Second batch prepared: all 8 roles now have a caller and a baseline. Committed and tested locally, not yet run on the runner.** **What's committed** - **Reusable workflow** (69e12d2): the role-lint step now also links the role's *bare* name (`eom`) as well as the repo name (`ansible-role-eom`). ansible-role-eom's skeleton `tests/test.yml` uses the bare name, so `syntax-check` failed, and that rule can't be baselined. The documented baseline command in `docs/ci-cd/adding-ci.md` has the same link, and the test table has today's results. - In each role, `.gitea/workflows/lint.yaml` (same manual-only caller as batch 1, push/PR trigger in its header) plus a generated `.ansible-lint-ignore`: | Role | Commit | Baseline entries (file + rule) | |---|---|---| | ansible-role-eom | DevOps/ansible-role-eom@73fd990 | 99 | | ansible-role-discourse | DevOps/ansible-role-discourse@04321c8 | 1 | | ansible-role-mcp-servers | DevOps/ansible-role-mcp-servers@e4923a6 | 7 | | ansible-role-listmonk | DevOps/ansible-role-listmonk@81ffa27 | 2 | | ansible-role-prometheus | DevOps/ansible-role-prometheus@197921d | 12 | - Submodules for eom, listmonk, mcp-servers and prometheus bumped in 13ca806. ansible-role-discourse isn't a submodule of this repo. CI files only, so nothing the roles deploy changes. None of these pushes started a run; I checked the Actions run lists. **Tested on the workstation**, by running the reusable workflow's `run:` step verbatim (extracted from the YAML) in a local build of the tools image 1.0.0, with `REPO` set as the job would set it: | Case | Result | |---|---| | eom, discourse, mcp-servers, listmonk, prometheus with their baselines | all pass | | gitea, www, dex (batch 1) with the changed step | still pass | | listmonk plus a new `tasks/extra.yml` with an unnamed `shell:` task | fails, on the new file only | | eom with the previous step (no bare-name link) | fails in `syntax-check` | `actionlint` passes on the changed reusable workflow and all five callers. **Noted while baselining:** ansible-role-eom's `tasks/matrix.yaml` sets the ingress `host` key twice with the same value, so it's harmless. It's in the baseline as `yaml[key-duplicates]`. That file also doesn't seem to be included from `tasks/main.yaml`; worth checking whether it's dead before anyone fixes it. **Why it stays open:** the acceptance asks for links to passing runs. That needs the runner fixes live and S8 (#41) to pass, then G1 (#49) to publish the tools image. When that happens: switch the eight callers to push/PR (in batches, per the shared-runner rule), delete ansible-role-gitea's `demo.yaml`, link the runs here, and close. — eom-cicd-roadmap
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: DevOps/software-infrastructure#53