b80361b788
ci/woodpecker/cron/drift Pipeline was successful
Add generator/render_ondemand.py rendering a kind: ondemand pipeline whose pre-step runs nix-estimate --json (asserts sizing.version==1), orders an EphemeralBuilder class:ci via nix-estimate --provision ci | kubectl apply, waits Ready, builds pinned via backend_options.kubernetes.nodeSelector (Option B plain-worker), and reaps the CR (runs_on success+failure). Keeps the GENERATED header + arch banner, no || true (reap uses --ignore-not-found). Adds manifests/ondemand-release-amd64.yaml + rendered example; render is pure and deterministic. render_thin_quartet skips kind: ondemand by design.
47 lines
2.4 KiB
YAML
47 lines
2.4 KiB
YAML
# Example estimator-driven on-demand CI target (oleks/ci-scripts#25).
|
|
#
|
|
# Renders with generator/render_ondemand.py (NOT the quartet renderer — the
|
|
# `kind: ondemand` dispatch is handled by its own script; render_thin_quartet
|
|
# skips this manifest as an unknown kind by design).
|
|
#
|
|
# SHAPE: a heavy amd64 release build that must NOT serialise through the single
|
|
# emmett-amd64 Woodpecker agent. The pre-step estimates the sizing, orders a
|
|
# fresh on-demand amd64 cloud node (EphemeralBuilder class: ci), waits for it to
|
|
# join armer k3s as a plain kubernetes.io/arch=amd64 worker, builds there, then
|
|
# reaps the node. See the reference order CR:
|
|
# builder-arbitrage config/samples/arbitrage_v1alpha1_ephemeralbuilder_ci-amd64-release-slot.yaml
|
|
#
|
|
# Fields:
|
|
# repo - logical name (used in the GENERATED header + out path)
|
|
# kind - `ondemand` (dispatch key for render_ondemand.py)
|
|
# target - nix flake attr to build/estimate (e.g. .#release)
|
|
# system - nix system double (x86_64-linux) fed to nix-estimate
|
|
# --system; the CR arch is derived by the estimator's
|
|
# provision.arch_for_system(system).
|
|
# arch - k8s/Go arch double (amd64) for the node label + the
|
|
# build step's nodeSelector pin. MUST be the k8s double,
|
|
# not the nix double (kubernetes.io/arch enum is amd64).
|
|
# provision_class - EphemeralBuilder class (ci) passed to --provision.
|
|
# build_run - the actual build command(s) run on the ordered node.
|
|
# wait_timeout - kubectl wait --for=condition=Ready timeout.
|
|
# kubeconfig_secret - (optional) Woodpecker secret holding a scoped SA
|
|
# kubeconfig; omit to use the step-pod's in-cluster SA.
|
|
# node_selector - (optional) extra nodeSelector keys merged onto the
|
|
# arch pin (reserved; the MVP needs only the arch pin).
|
|
# orchestrator_image - (optional) image with nix-estimate + kubectl + jq.
|
|
# build_image - (optional) the repo's build image.
|
|
# memory_request /
|
|
# memory_limit - (optional) build step k8s memory sizing.
|
|
repo: ondemand-release-amd64
|
|
kind: ondemand
|
|
target: .#release
|
|
system: x86_64-linux
|
|
arch: amd64
|
|
provision_class: ci
|
|
wait_timeout: 1200s
|
|
build_run: |
|
|
nixos-ci-entrypoint true
|
|
PUBLISH=1 nix run .#publish
|
|
memory_request: 8Gi
|
|
memory_limit: 32Gi
|