release: cut v2.3.0 — the A2A interoperability surface (RFC 0020) #53
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: ci | |
| on: | |
| push: | |
| branches: [main, rewrite/mcp-native-agent] | |
| pull_request: | |
| env: | |
| CARGO_TERM_COLOR: always | |
| permissions: | |
| contents: read | |
| jobs: | |
| # Format, lint, and the full test suite. agentd is a Linux-native daemon | |
| # (PR_SET_PDEATHSIG, the subreaper, waitpid, cgroups, unix sockets), so CI is | |
| # Linux-only — there is no macOS/Windows runtime target. `--all-features` so the | |
| # feature-gated modules (tls/vsock/serve-mcp/cron/metrics/otel) are linted and | |
| # tested too; without it a gated module can rot unseen. | |
| gate: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: dtolnay/rust-toolchain@stable | |
| with: | |
| components: rustfmt, clippy | |
| - uses: Swatinem/rust-cache@v2 | |
| - run: cargo fmt --all --check | |
| - run: cargo clippy --workspace --all-targets --all-features -- -D warnings | |
| # The whole workspace under all features: agentd's feature-gated tests | |
| # (serve_mcp / otel_e2e / …) and the black-box agentd-conformance suite, | |
| # which builds + drives the real binary, both run here. | |
| - run: cargo test --workspace --all-features | |
| # The capability-pruning story, proven in CI: every feature combination an | |
| # operator is likely to ship must build + test clean on its own (feature | |
| # unification under `--all-features` can hide a broken solo build). | |
| features: | |
| runs-on: ubuntu-latest | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| features: | |
| - "" # default (the 3-dep minimalism build) | |
| - "--features serve-mcp" | |
| - "--features cron" | |
| - "--features metrics" | |
| - "--features otel" | |
| - "--features tls" | |
| - "--features vsock" | |
| - "--features metrics,serve-mcp,cron,otel" # the image's cloud-native set | |
| - "--all-features" | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: dtolnay/rust-toolchain@stable | |
| - uses: Swatinem/rust-cache@v2 | |
| - run: cargo test -p agentd ${{ matrix.features }} | |
| # Minimalism is the moat: the DEFAULT build must stay at exactly three direct | |
| # dependencies (serde, serde_json, libc) — no async runtime, no TLS, no C. This | |
| # fails the build if an unearned dependency sneaks in. | |
| minimalism: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: dtolnay/rust-toolchain@stable | |
| - uses: Swatinem/rust-cache@v2 | |
| - name: Assert the default build has exactly 3 direct deps | |
| run: | | |
| # `--prefix none` lists one package per line with no tree glyphs, so the | |
| # count is charset-independent (cargo tree emits ASCII art off a TTY, so | |
| # a `├`/`└` grep counts 0 in CI). First line is the agentd root; drop it. | |
| deps=$(cargo tree -p agentd --depth 1 --edges normal --prefix none | tail -n +2 | grep -c .) | |
| echo "direct deps: $deps" | |
| if [ "$deps" -ne 3 ]; then | |
| echo "::error::default build must have exactly 3 direct deps (serde, serde_json, libc); found $deps" | |
| cargo tree -p agentd --depth 1 --edges normal --prefix none | |
| exit 1 | |
| fi | |
| # Build the OCI image from the Dockerfile (single-arch smoke build, no push) and | |
| # prove the static binary runs — so a Dockerfile or static-link regression is | |
| # caught on every PR, not at release time. | |
| image: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: docker/setup-buildx-action@v3 | |
| - name: Build image (amd64, load locally) | |
| uses: docker/build-push-action@v6 | |
| with: | |
| context: . | |
| load: true | |
| tags: agentd:ci | |
| - name: Smoke-test the image | |
| run: | | |
| docker run --rm agentd:ci --version | |
| docker run --rm agentd:ci --help | grep -q -- '--metrics-addr' |