Files
acdl/pipelines/ci.yaml
T
Jon Chery e050e65158
acdl-ci / Lint (push) Successful in 8s
acdl-ci / Test (push) Successful in 14s
acdl-ci / Platform check-only (offline) (push) Successful in 9s
feat(P19): central pipeline contract + shell reproducibility + output streaming (v1.4.1)
---ci---
project: acdl
phase: 19
milestone: v1.4
status: execute
---

Add declarative pipeline contract (schemas/pipeline.schema.json +
pipelines/ci.yaml) as single source of truth for both Gitea Actions (dev)
and GitHub Actions (production) workflows. Both workflow files are
byte-identical and validated against the contract by 32 new tests.

Add scripts/run_ci.sh for shell reproducibility — mirrors the CI pipeline
locally (lint → test → check-only), exits 0 with 'CI PIPELINE OK'.

Update scripts/run_platform.sh to stream output by default: terraform
init/validate/plan via tee, Checkov compliance results with per-record
severity/rule/pass-fail, and emitted Terraform in --check-only. New
--quiet flag for log-only mode.

Requirements: REQ-43 (central pipeline contract), REQ-44 (shell
reproducibility), REQ-45 (output streaming). 122 tests pass (90 + 32).
2026-07-22 15:10:54 +00:00

49 lines
1.7 KiB
YAML

# ACDL Central Pipeline Contract (v1.4)
#
# This is the single source of truth for the CI/CD pipeline. Both
# .gitea/workflows/ci.yml (Gitea Actions, dev) and
# .github/workflows/ci.yml (GitHub Actions, production) implement the
# stages, commands, triggers, and runner declared here.
# scripts/run_ci.sh mirrors the same stages for shell reproducibility.
#
# A test (tests/test_pipeline_contract.py) validates that both workflow
# YAMLs conform to this contract and that run_ci.sh runs the same commands.
#
# The contract does NOT replace workflow YAML syntax — it declares the
# *intent* that the forge-specific workflows implement. The workflow files
# use Gitea/GitHub Actions syntax (checkout, setup-python, run blocks);
# this contract declares what those blocks must contain.
#
# Validated against schemas/pipeline.schema.json.
name: acdl-ci
environment: dev
triggers:
push: [main]
pull_request: [main]
runner: ubuntu-latest
python_version: "3.12"
stages:
- name: lint
description: Compile all Python files (py_compile)
command: |
python3 -m py_compile \
acdl_platform/confidence_signal.py \
acdl_platform/outbox_writer.py \
adapters/terraform/adapter.py \
adapters/terraform/policy/checkov_adapter.py \
scripts/push_consumer_image.py
required: true
- name: test
description: Run the pytest test suite offline
command: python3 -m pytest tests/ -v --tb=short
install: pip install -r requirements-test.txt
required: true
- name: check-only
description: Run the platform pipeline offline (no AWS/Checkov/DynamoDB)
command: bash scripts/run_platform.sh --check-only
install: pip install jsonschema pyyaml boto3
required: true