95 lines · 3.5 KiBRaw
- # Native Forge CI for Ronéo (schema 2, Rust 1.100.0)
- # - [cargo]: format, clippy, tests planned per-crate by Forge's Cargo model
- # - [jobs.gitleaks]: required secret scan for public repository landings
- # - [jobs.release-linux]: static musl Linux release archives (`linux-amd64`,
- # `linux-arm64`) packaged as an OCI image index for Forge's release worker
- schema = 2
- [variables]
- CARGO_HOME = "$CI_PROJECT_DIR/.cache/forge-cargo"
- RUST_IMAGE = "$CLEYROP_REGISTRY/external/library/rust:1.100.0-slim-trixie@sha256:24516ae4487ab804e3db145c93f7240e58e225587ab9b7c62ea31a218727bf67"
- [cargo]
- workspace = ""
- checks = ["format", "clippy", "tests"]
- reads = ["crates:public", "rust:dist"]
- tests_reads = ["apt:debian"]
- tests_warm = ["target", ".cache/forge-cargo/registry"]
- [cargo.job]
- image = "$CLEYROP_REGISTRY/external/library/rust:1.100.0-slim-trixie@sha256:24516ae4487ab804e3db145c93f7240e58e225587ab9b7c62ea31a218727bf67"
- script = [
- "rustup component add clippy rustfmt",
- "{argv}",
- ]
- [cargo.tests]
- image = "$CLEYROP_REGISTRY/external/library/rust:1.100.0-slim-trixie@sha256:24516ae4487ab804e3db145c93f7240e58e225587ab9b7c62ea31a218727bf67"
- script = [
- "command -v git >/dev/null || (apt-get update -qq && apt-get install -y -qq --no-install-recommends git >/dev/null)",
- "{argv}",
- ]
- # Required secret scan for every change on a published repository (PUBLIC-FORGE.md §6.5).
- [jobs.gitleaks]
- inputs = ["**"]
- image = { name = "$CLEYROP_REGISTRY/external/zricethezav/gitleaks:v8.24.2@sha256:b5918eb91b8d2473cec722f066abb4352e4ffdc4ec9f4283ec143aba9ec9ebc4", entrypoint = [""] }
- script = [
- "gitleaks detect --source . --no-banner --redact --log-opts=HEAD",
- ]
- # Static Linux release archives (`linux-amd64`, `linux-arm64`) packaged as an
- # OCI image index (`application/vnd.forge.archive.v1`) and pushed by the agent
- # to the host's pool registry for Forge's public release worker
- # (PUBLIC-FORGE-RELEASES.md §4).
- [jobs.release-linux]
- inputs = [
- "Cargo.toml",
- "Cargo.lock",
- "rust-toolchain.toml",
- "LICENSE",
- "crates/**",
- "ci/binaries/linux/build-archives.sh",
- ]
- on = { runs = ["landing"], trust = ["protected"] }
- reads = ["crates:public", "rust:dist"]
- image = "$CLEYROP_REGISTRY/external/library/rust:1.100.0-slim-trixie@sha256:24516ae4487ab804e3db145c93f7240e58e225587ab9b7c62ea31a218727bf67"
- layout = "release/linux/oci"
- outputs = ["DOCKER_DESTINATION"]
- script = [
- "bash ci/binaries/linux/build-archives.sh $CI_COMMIT_SHA",
- ]
- [jobs.release-linux.variables]
- DOCKER_DESTINATION = "$CLEYROP_REGISTRY/public/roneo-release-linux"
- # Signed & notarised macOS arm64 binary built on Forge's macOS signing host (`forge-mac-1`).
- [jobs.binaries-macos]
- inputs = [
- "Cargo.toml",
- "Cargo.lock",
- "rust-toolchain.toml",
- "crates/**",
- "ci/binaries/macos/build.sh",
- ]
- on = { runs = ["landing"], trust = ["protected"] }
- detached = true
- allow_failure = true
- tags = ["platform:darwin/arm64"]
- resource_group = "macos-signing"
- image = "$CLEYROP_REGISTRY/external/library/rust:1.100.0-slim-trixie@sha256:24516ae4487ab804e3db145c93f7240e58e225587ab9b7c62ea31a218727bf67"
- outputs = ["roneo-macos.json"]
- inline = ["roneo-macos.json"]
- artifacts = { paths = ["roneo-macos.json"] }
- notarisations = "notarisations.json"
- script = ["bash ci/binaries/macos/build.sh $CI_COMMIT_SHA"]
- [jobs.binaries-macos.variables]
- FORGE_MACOS_POOL = "$CLEYROP_REGISTRY/forge-mac-binaries/roneo-binaries"
- FORGE_SIGNING = "keychain"
- FORGE_SIGNING_TEAM = "4SKW2Z97A2"
- FORGE_NOTARY_PROFILE = "forge-notary"
- [release]
- task = "release-linux"
- archives = ["linux-amd64", "linux-arm64"]