Files
computer-playbook/.github/workflows/ci-orchestrator.yml
T
kevinveenbirkenbachandClaude Opus 4.7 7ad7b5e76c feat(lint): add lint-playwright for per-role spec parse checks
Each role's Playwright spec is staged the same way `test-e2e-playwright` does at deploy time (central config + personas tree + service-gating) and `npx playwright test --list` runs against it. `--list` skips the browser launch and any test body, so this catches refactor regressions like missing helpers, broken exports, or syntax errors in seconds instead of waiting for a full deploy. Stub env values keyed off the variable-name suffix satisfy the few specs that build URLs or call `.replace()` at module-load time.

Parallelism caps at `INFINITO_WORKER_CPU` (same env knob as `scripts/make/parallel.sh`); output is replayed in `SPEC_FILES` order after all workers drain so stdout stays deterministic. `@playwright/test` ships as a devDep via the existing eslint `npm ci`. Workflow wires into `ci-orchestrator.yml` behind the `lint-gate`.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-22 10:24:32 +02:00

253 lines
7.4 KiB
YAML

name: "🎵 CI: Orchestrator"
on:
workflow_call:
inputs:
distros:
description: "Space-separated distro list"
required: false
type: string
default: "arch debian ubuntu fedora centos"
whitelist:
description: "Optional space-separated whitelist of app ids"
required: false
type: string
default: ""
image_wait_attempts:
description: "Polling attempts for waiting on prebuilt or mirrored images"
required: false
type: string
default: "1980"
image_wait_sleep_seconds:
description: "Polling interval in seconds for waiting on prebuilt or mirrored images"
required: false
type: string
default: "10"
concurrency:
group: infinito-test-${{ github.ref }}
cancel-in-progress: false
permissions:
actions: write
contents: read
packages: write
security-events: write
jobs:
wait-fork-prereq-run:
name: ⏳ Wait for fork run
runs-on: ubuntu-latest
steps:
- name: Mark fork prerequisites as ready outside fork PRs
if: ${{ github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == github.repository }}
shell: bash
run: |
set -euo pipefail
echo "Fork prerequisites are implicitly ready outside fork pull_request events."
- name: Checkout trusted workflow repo (helpers)
if: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name != github.repository }}
uses: actions/checkout@v6
with:
ref: ${{ github.event.pull_request.base.sha }}
persist-credentials: false
- name: Login to GHCR for CI image checks
if: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name != github.repository }}
uses: docker/login-action@4907a6ddec9925e35a0a9e82d7399ccc52663121 # v4.1.0
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Wait for privileged fork CI images
if: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name != github.repository }}
shell: bash
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
WORKFLOW_FILE: entry-pull-request-change.yml
TARGET_EVENT: pull_request_target
PR_NUMBER: ${{ github.event.pull_request.number }}
PR_HEAD_SHA: ${{ github.event.pull_request.head.sha }}
PR_UPDATED_AT: ${{ github.event.pull_request.updated_at }}
INFINITO_DISTROS: "arch debian ubuntu fedora centos"
IMAGE_TAG: ci-${{ github.sha }}
WAIT_ATTEMPTS: ${{ inputs.image_wait_attempts }}
WAIT_SLEEP_SECONDS: ${{ inputs.image_wait_sleep_seconds }}
run: ./scripts/meta/wait/images.sh
fork-prereqs-ready:
name: 🚦 Gate Dependencies
needs: wait-fork-prereq-run
if: ${{ always() }}
runs-on: ubuntu-latest
steps:
- name: Assert privileged prerequisites are ready
shell: bash
run: |
set -euo pipefail
result="${{ needs.wait-fork-prereq-run.result }}"
if [[ "${result}" != "success" && "${result}" != "skipped" ]]; then
echo "Fork prerequisites are not ready. wait-fork-prereq-run=${result}" >&2
exit 1
fi
echo "Fork prerequisites are ready."
# Security Checks
security-codeql:
uses: ./.github/workflows/security-codeql.yml
# Linting
lint-ansible:
uses: ./.github/workflows/lint-ansible.yml
lint-docker:
uses: ./.github/workflows/lint-docker.yml
lint-python:
uses: ./.github/workflows/lint-python.yml
lint-shell:
uses: ./.github/workflows/lint-shell.yml
lint-markdown:
uses: ./.github/workflows/lint-markdown.yml
lint-makefile:
uses: ./.github/workflows/lint-makefile.yml
lint-javascript:
uses: ./.github/workflows/lint-javascript.yml
lint-playwright:
uses: ./.github/workflows/lint-playwright.yml
lint-gate:
name: 🚦 Gate lint
needs:
- lint-ansible
- lint-python
- lint-docker
- lint-shell
- lint-markdown
- lint-makefile
- lint-javascript
- lint-playwright
runs-on: ubuntu-latest
steps:
- run: echo "lint gate passed"
# Code Testing
test-code-integration:
uses: ./.github/workflows/test-code-integration.yml
test-code-lint:
uses: ./.github/workflows/test-code-lint.yml
test-code-external:
uses: ./.github/workflows/test-code-external.yml
test-code-unit:
uses: ./.github/workflows/test-code-unit.yml
test-code-gate:
name: 🚦 Gate code
needs: [test-code-integration, test-code-lint, test-code-external, test-code-unit]
runs-on: ubuntu-latest
steps:
- run: echo "code gate passed"
# Gate for the code Quality
code-quality-gate:
name: 🚦 Gate Quality
needs:
- lint-gate
- test-code-gate
- security-codeql
runs-on: ubuntu-latest
steps:
- run: echo "Quality Checks passed"
# Build Docker Images
build-ci-images:
needs:
- code-quality-gate
uses: ./.github/workflows/images-build-ci.yml
with:
distros: "arch debian ubuntu fedora centos"
concurrency_channel: ci-orchestrator-build-consumer
secrets: inherit
# Test DNS configuration
test-dns:
needs:
- build-ci-images
uses: ./.github/workflows/test-dns.yml
with:
distros: "arch debian ubuntu fedora centos"
# Sync Missing Images
images-mirror-missing:
uses: ./.github/workflows/images-mirror-missing.yml
with:
concurrency_channel: ci-orchestrator-mirror-consumer
image_wait_attempts: ${{ inputs.image_wait_attempts }}
image_wait_sleep_seconds: ${{ inputs.image_wait_sleep_seconds }}
secrets: inherit
# Deploy tests
test-deploy-server:
needs:
- test-dns
- images-mirror-missing
uses: ./.github/workflows/test-deploy-server.yml
with:
distros: ${{ inputs.distros }}
whitelist: ${{ inputs.whitelist }}
test-deploy-universal:
needs:
- test-dns
- images-mirror-missing
uses: ./.github/workflows/test-deploy-universal.yml
with:
distros: ${{ inputs.distros }}
whitelist: ${{ inputs.whitelist }}
test-deploy-workstation:
needs:
- code-quality-gate
- build-ci-images
uses: ./.github/workflows/test-deploy-workstation.yml
with:
distros: ${{ inputs.distros }}
whitelist: ${{ inputs.whitelist }}
# Test Installation
test-install-make:
uses: ./.github/workflows/test-install-make.yml
needs:
- code-quality-gate
test-install-pkgmgr:
uses: ./.github/workflows/test-install-pkgmgr.yml
needs:
- code-quality-gate
test-install-gate:
name: 🚦 Gate installation
needs:
- test-install-make
- test-install-pkgmgr
runs-on: ubuntu-latest
steps:
- run: echo "Installation is possible via pkgmgr and make"
# Test Development Environment
test-development:
uses: ./.github/workflows/test-environment.yml
needs:
- images-mirror-missing
- code-quality-gate
secrets: inherit
done:
name: 🏁 Finish pipeline
needs:
- test-deploy-server
- test-deploy-universal
- test-deploy-workstation
- test-install-gate
- test-development
runs-on: ubuntu-latest
steps:
- name: Done
run: echo "All checks passed."