|
| 1 | +# CLAUDE.md |
| 2 | + |
| 3 | +## Project overview |
| 4 | + |
| 5 | +This is **scality/workflows**, a repository of reusable GitHub Actions workflows shared across the Scality organization. Downstream repos call these workflows via `workflow_call`. |
| 6 | + |
| 7 | +## Repository structure |
| 8 | + |
| 9 | +- `.github/workflows/` — Reusable workflow definitions (the core asset) |
| 10 | +- `docs/` — MkDocs Material documentation for each workflow |
| 11 | +- `tests/` — Dockerfiles used as fixtures to validate workflows on PR |
| 12 | +- `mkdocs.yml` — Documentation site configuration |
| 13 | +- `requirements.txt` — Python dependency for docs (`mkdocs-material`) |
| 14 | + |
| 15 | +## Workflows |
| 16 | + |
| 17 | +| File | Purpose | |
| 18 | +|------|---------| |
| 19 | +| `docker-build.yaml` | Build and push Docker images with Buildx, caching, multi-platform support | |
| 20 | +| `trivy.yaml` | Container vulnerability scanning, uploads SARIF to GitHub Security tab | |
| 21 | +| `lfs-warning.yaml` | Validates file sizes in PRs, warns about files not tracked by Git LFS | |
| 22 | +| `claude-code-review.yml` | AI-powered PR review via Vertex AI | |
| 23 | + |
| 24 | +## Conventions |
| 25 | + |
| 26 | +- Workflow files use `.yaml` extension (except `claude-code-review.yml`) |
| 27 | +- All workflows use `workflow_call` trigger with typed `inputs` and `secrets` |
| 28 | +- Secrets have sensible defaults where possible (e.g., `GITHUB_TOKEN` for registry auth) |
| 29 | +- Actions are pinned to major version tags (e.g., `@v6`, `@v3`) |
| 30 | +- `tests.yaml` calls all workflows locally (`./.github/workflows/...`) to validate on PR |
| 31 | + |
| 32 | +## Testing |
| 33 | + |
| 34 | +There is no test framework. Workflows are tested by `tests.yaml` which calls each reusable workflow with test fixtures from `tests/docker/`. |
| 35 | + |
| 36 | +## Documentation |
| 37 | + |
| 38 | +Documentation is built with MkDocs Material (`mkdocs build --strict`). When adding or modifying a workflow, update the corresponding page in `docs/`. |
| 39 | + |
| 40 | +## Downstream impact |
| 41 | + |
| 42 | +Changes to workflow `inputs`, `secrets`, or `outputs` can break consuming repos. Treat these as public API surfaces — avoid removing or renaming parameters without a migration path. |
0 commit comments