mirror of
https://github.com/hanzoai/engine.git
synced 2026-11-20 23:45:50 +00:00
39 lines
1.7 KiB
YAML
39 lines
1.7 KiB
YAML
# Canonical CI/CD config for hanzoai/engine — read by the hanzoai/ci reusable
|
|
# (.hanzo/workflows/cicd.yml) and by platform.hanzo.ai.
|
|
#
|
|
# The Zen inference engine: a 23-crate Rust workspace.
|
|
#
|
|
# The image is declared at the end of this file and built by the build door;
|
|
# it is the Dockerfile's one builder. The GPU/FFI/release lanes sit beside it.
|
|
#
|
|
# `rustup component add rustfmt` first: the toolchain this workflow provisions
|
|
# (dtolnay/rust-toolchain@stable) installs the compiler ALONE, so `cargo fmt`
|
|
# dies with "'cargo-fmt' is not installed for the toolchain" before reading a
|
|
# line of code — a red run that says nothing about the repo. ci.yml buys this
|
|
# with `components:` on the toolchain action; the provision step above is not
|
|
# ours to configure, so the gate buys it itself. It is idempotent.
|
|
#
|
|
# The gates are the repo's own (.hanzo/workflows/ci.yml), cheapest first: fmt
|
|
# is seconds and catches what needs no compiler, then a full type-check of every
|
|
# member. `cargo check` — not `cargo build` — because nothing here consumes a
|
|
# binary; the question this gate asks is whether the workspace still compiles.
|
|
|
|
test:
|
|
# Every first-party path is /v1/...; a quoted "/api/" or a joined `}api/`
|
|
# outside Markdown (prose that cites third-party APIs) is a regression.
|
|
- name: v1-only
|
|
run: |
|
|
! git grep -nE -e '["(`]/api/' -e "'/api/" -e '}api/' -- ':!*.md' ':!hanzo.yml'
|
|
- name: fmt
|
|
run: rustup component add rustfmt && cargo fmt --all -- --check
|
|
- name: check
|
|
run: cargo check --workspace
|
|
|
|
# Built by the build door, one BuildKit Job per platform.
|
|
images:
|
|
- name: engine
|
|
context: .
|
|
dockerfile: Dockerfile
|
|
repo: ghcr.io/hanzoai/engine
|
|
platforms: [linux/amd64]
|