Pipelines
What a branchd pipeline is, what is available today, and where each task and key is documented.
Available in repositories branchd reads pipeline files for. It is switching repositories on one at a time: until yours is, it keeps running its
.forge-ci.yamlor.xeonr-ci.yaml. See What is available.
A pipeline is a YAML file in your repository, .branchd/pipelines/<name>.yaml,
that says when it runs (on:) and which jobs it runs (jobs:). Each job runs
its steps in a container, with your repository already checked out. Jobs run
in parallel unless one needs another. Everything about which jobs run is
decided before the run starts, so branchd ci plan can tell you, for any
branch or event, which jobs will run and why.
The syntax follows GitHub Actions closely: on, jobs, steps, needs,
if, matrix, ${{ }} expressions and uses:. It is not GitHub Actions:
the differences are in Coming from GitLab CI
and throughout the reference.
For agents and editors
- The complete reference in one file, as Markdown:
/branchd/pipelines/reference.md. Every key, every refusal rule and every limit, on one page. - Every page of this section in one file:
/branchd/pipelines/llms-full.txt, with an index at/branchd/pipelines/llms.txt. The site's own index is/llms.txt. - The JSON Schema of a pipeline file, for editors:
https://docs.xeonr.io/schemas/branchd/pipeline.json(andstep.json,packages.json). See Editor support and the schema. - The loop for an agent writing a pipeline: Writing pipelines with an AI agent.
Every YAML example in these pages is a file that branchd's compiler accepts: the examples are compiled for every event they list before the pages change.
Start here
Tasks
Each page is one task and one complete file you can copy.
More tasks: a Go service with a database, a Node.js project, deploy, caches and artifacts, outputs, secrets, environments and approval, paths, several pipelines, steps and pipelines of another repository, presets.
Reference
What is available
Pipeline files are on in production, and branchd is switching repositories
to them one at a time. A repository that is not switched on runs its
.forge-ci.yaml or .xeonr-ci.yaml exactly as before, and ignores
.branchd/pipelines/. In a repository that is switched on:
| Part | State |
|---|---|
Jobs, steps, needs, if, matrix, services, caches, artifacts, secrets, environments, manual jobs, superseding | Available |
| The automatic checkout (no git needed in the image) | Available |
| Push checks: a push whose changed pipeline file does not compile is refused, with file and line | Available |
| Manual runs with inputs, schedules, triggers of this repository's own pipelines | Available |
| Composite steps and reusable pipelines, of this repository or another | Available |
Typed steps (uses: branchd/steps/<step>@v1), alone or isolated: true among run: steps | Available |
The job token and permissions: | Available |
Presets of another repository (preset: {uses: <group>/<repo>/<path>@v1}) | Available |
| Optional secrets of a step | Available |
Not available yet, each said again on the page it concerns:
- Triggering another repository's pipeline works only when that repository is switched on too; today a trigger to any other repository is refused. A repository triggering its own pipelines works.
- A preset of the same repository (
preset: {uses: ./<path>}) is refused; a preset comes from another repository. - Starting a manual run with inputs from the console: the console starts a run of a branch only. Use the CLI or the API (Manual runs).
- The CLI features these pages use,
branchd run start --pipeline … --input …andbranchd ci lintchecking every event a file lists, are in the next CLI release (0.39.0).branchd ci lintandci planof earlier releases (0.33.0 and later) read pipeline files, but check fewer situations. - Refused for now, each with a clear message:
max-parallel,fail-fast: true, amatrix:on a job that calls a pipeline, a lock over a whole pipeline (concurrency.groupat the top level),checkout: {submodules}, a jobif:that reads another job's outputs, a stepif:that readssteps.*.outputs. - Steps published by other products (
uses: strata/migrate@1). - A
run:job's outputs as animage:or a typed step'swith:: only a typed step's outputs reach those (Outputs). - The branchd CLI inside a job: it is not in job images. A job can
install it with
curl -fsSL https://updater.xeonr.io/96/install.sh -o install.sh && env -u BRANCHD_TOKEN sh install.sh(the installer readsBRANCHD_TOKENas its own token, so the job's token is left out). The job token also works withcurlandgit(The job token).