Skip to content

feat: add build provenance tracking to engine images - #796

Merged
k-rister merged 3 commits into
masterfrom
engine-provenance
Apr 16, 2026
Merged

feat: add build provenance tracking to engine images#796
k-rister merged 3 commits into
masterfrom
engine-provenance

Conversation

@k-rister

Copy link
Copy Markdown
Contributor

Summary

  • Track which repo state produced each engine image by embedding provenance data as OCI annotations and a file at /etc/crucible/build-provenance.json
  • Provenance includes: source controller (hostname + IP), rickshaw client/server versions with dirty detection, all contributing repos with commit hash, dirty flag, diff-hash, and full diff
  • Rickshaw tracked separately as client (controller-side) and server (service-side) since they may differ in remote sourcing setups
  • Also removes the obsolete fedora userenv compat entry from workshop.json (crucible#545 renamed it to crucible-controller)

Files changed

  • rickshaw-run — compute provenance and include in source-images input
  • schema/source-images-input.json — add required provenance field
  • rickshaw-source-images-client — pass provenance through to API
  • source-images-service/models/requests.py — add Provenance models
  • source-images-service/core/image_sourcer.py — generate annotations and provenance file, embed in last build stage
  • workshop.json — remove fedora compat entry

Test plan

  • Tested with crucible run — provenance data written to source-images input JSON
  • Dirty detection working — rickshaw shows dirty with diff when changes present
  • Clean repos show dirty=false with no diff data
  • CI passes

🤖 Generated with Claude Code

k-rister and others added 2 commits April 14, 2026 21:49
Track which repo state produced each engine image by embedding
provenance data as OCI annotations and a file inside the image at
/etc/crucible/build-provenance.json.

Provenance includes:
- Source controller hostname and IP
- Rickshaw client version (controller-side) with dirty detection
- Rickshaw server version (service-side) with dirty detection
- All contributing repos (benchmarks, tools, utilities, core) with
  commit hash, dirty flag, diff-hash, and full diff for dirty repos

Changes:
- rickshaw-run: compute provenance and include in source-images input
- schema/source-images-input.json: add required provenance field
- rickshaw-source-images-client: pass provenance through to API
- source-images-service models: add Provenance/RepoProvenance models
- image_sourcer: generate annotations and provenance file requirement,
  embed in last build stage

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
The controller userenv was renamed from 'fedora' to
'crucible-controller' in crucible#545. The fedora entry was kept
temporarily for backwards compatibility during the transition.
Now that the rename is merged, the fedora entry is dead code.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@k-rister k-rister self-assigned this Apr 15, 2026
@k-rister
k-rister requested a review from a team April 15, 2026 02:51
@project-crucible-tracking project-crucible-tracking Bot moved this to In Progress in Crucible Tracking Apr 15, 2026
@k-rister
k-rister marked this pull request as draft April 15, 2026 13:49
Add the provenance requirement alongside each stage's own requirement
instead of appending it as a separate final stage. This ensures every
intermediate stage image has both the provenance file and annotations,
making all stages traceable to their source repos.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@k-rister
k-rister marked this pull request as ready for review April 15, 2026 18:33
@k-rister
k-rister merged commit 6cc6d7a into master Apr 16, 2026
1957 of 1968 checks passed
@github-project-automation github-project-automation Bot moved this from In Progress to Done in Crucible Tracking Apr 16, 2026
@k-rister
k-rister deleted the engine-provenance branch April 16, 2026 00:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

1 participant