3.7 KiB
infra — shared CI, staged
Staging area for the two repositories that hold CI once it stops being per-repo. Nothing here
is live yet: these files are reviewed in the monorepo, then pushed to their own repos on
git.vectur45.com.
| Repo to create | Holds | From |
|---|---|---|
infra/ci-workflows |
reusable pipelines (on: workflow_call) — dotnet8-ci, node-ci, node-service-ci |
ci-workflows/ |
infra/ci-actions |
composite actions (capped bake, bundle extract, compose deploy, smoke) | not written yet |
Why an org rather than trent
self: references and workflow_call paths both embed the owner, so moving later means editing
every caller. An org is also the right home for the mirrored ci-ubuntu package. If you keep
trent, substitute it everywhere below — but decide once.
Creating them
- Create the
infraorganisation ongit.vectur45.com. - Create
ci-workflows(private is fine) and push the contents ofci-workflows/to it. - In that repo: Settings → Actions → General → collaborative owners, add the owners whose private repos need to read it. Gitea 1.26+ requires this for private reusable workflows.
- Tag it
v1. Callers pin the tag, never a branch.
Currently staged for v1.1 (additive — @v1 callers keep working):
node-ci.yml gains post_build_command with a documented phase order; node-service-ci.yml
is new. Push and tag v1.1, then move callers when they need the new inputs.
Referencing
jobs:
backend:
uses: infra/ci-workflows/.gitea/workflows/dotnet8-ci.yml@v1
with:
working_directory: GrowthOS
solution: GrowthOS.sln
test_projects: |
tests/GrowthOS.UnitTests/GrowthOS.UnitTests.csproj
tests/GrowthOS.IntegrationTests/GrowthOS.IntegrationTests.csproj
tests/GrowthOS.AgentEvals/GrowthOS.AgentEvals.csproj
Runner 4.0 also added uses: self:{owner}/{repo}@{ref} for actions on this instance. Whether
that prefix works for reusable workflows is unverified — use the plain owner/repo/path@ref
form above until it is.
Gitea-specific constraints these encode
| Constraint | Why |
|---|---|
inputs: are explicit, never gitea.event.inputs |
Not propagated into reusable workflows as of Gitea 1.27.2 |
One label in runs_on |
Multi-label runs-on: [a, b] is documented incomplete |
No jobs.<id>.environment |
Ignored by Gitea — there are no approval gates |
Artifact actions on @v4, both ends |
v3 and v4 use different backends and do not interoperate |
builtin:checkout |
Runner 4.0; no Node runtime, no github.com round-trip |
| Service containers by name, never published | The runner builds a per-job network with DNS aliases |
DOTNET_PROCESSOR_COUNT=1 on every test step |
2 vCPU shared with Gitea; uncapped testhost crashes service Postgres |
Source of truth for all of these: ../platform/observed-state.md.
What stays in the caller
A reusable workflow cannot accept injected steps, so anything repo-specific arrives as an input
(pre_build_command, test_env, extra_check_command) or stays in the caller as its own job.
GrowthOS's change-detection job is the latter: it needs fetch-depth: 0 and a repo-specific path
map, so it remains in .gitea/workflows/ci.yml.
Next
- Push
ci-workflows, tagv1. - Convert GrowthOS's
backendandfrontendjobs to callers; confirm green. - Extract the CD composite actions into
ci-actions— the capped bake, thedocker create/docker cpbundle extract, the compose deploy, the smoke test. - Onboard a second project. That is the step that proves the inputs are sufficient; design alone will not.