Skip to content

fix(container): drop ldconfig's aux-cache so the image builds reproducibly - #492

Merged
hyperpolymath merged 2 commits into
mainfrom
claude/container-repro-aux-cache
Nov 10, 2026
Merged

hyperpolymath merged 2 commits into
mainfrom
claude/container-repro-aux-cache

Conversation

@hyperpolymath

Copy link
Copy Markdown
Owner

Summary

Container Build Verification fails on main with "The Containerfile is not reproducible". Two --no-cache --timestamp 0 builds of the same commit differ in exactly one layer.

I read the per-path fingerprints from the two build jobs of run 42868217511. Only one path differs: /var/cache/ldconfig/aux-cache. Wolfi's apk commit hook (etc/apk/commit_hooks.d/ldconfig-commit.sh) runs ldconfig after apk add in the runtime stage, and the aux-cache records the build host's inode numbers and timestamps.

The CI drift report never named that path itself. Newer gh releases refuse to print job logs that contain ANSI escape codes ("the response contains terminal escape sequences"), so both fingerprint reads failed, and the step fell back to "only the layer comparison is available".

Changes

  • Containerfile: in the runtime stage, the apk add step now ends with && rm -f /var/cache/ldconfig/aux-cache. ld.so.cache is deterministic and stays.
  • .github/workflows/container-ci.yml: the drift step fetches job logs with curl instead of gh api. Older gh releases (2.89, for example) reject the --allow-escape-sequences override, so curl works with every version. -L follows the signed redirect and does not send the token to the other host. The existing grep still keeps only 64-hex digest lines.

RSR Quality Checklist

Required

  • Tests pass: bash scripts/ci/test-fs-fingerprint.sh passes
  • No secrets, credentials, or .env files included
  • SPDX license headers present (unchanged)

Testing

  • I ran the new curl pipeline on the 2 build logs of run 42868217511. It extracts 4320 fingerprint lines from each log, and fs-fingerprint-drift.sh then reports exactly var/cache/ldconfig/aux-cache.
  • There is no container daemon in this session, so this PR's CI is the test that the image is now reproducible.
  • Elsewhere: no other estate repo runs this reproducibility check, so this is the only place it fails.

Generated by Claude Code

…cibly

Container Build Verification fails on main: two --no-cache --timestamp 0
builds of one commit differ in one layer. The per-path fingerprints the
build jobs print show the only changed path is
/var/cache/ldconfig/aux-cache. Wolfi's apk commit hook runs ldconfig
after `apk add` in the runtime stage, and the aux-cache records the
build host's inode numbers and timestamps. Remove it in the same RUN;
ld.so.cache is deterministic and stays.

The drift report never named that path in CI: newer gh releases refuse
to print job logs that contain ANSI escape codes ("the response contains
terminal escape sequences"), so both fingerprint reads failed. Older gh
releases lack the override flag, so fetch the logs with curl instead;
only 64-hex digest lines pass the existing grep.

Checked against run 42868217511's two build logs: the curl pipeline
extracts 4320 fingerprint lines from each, and fs-fingerprint-drift.sh
reports exactly var/cache/ldconfig/aux-cache. test-fs-fingerprint.sh
passes. The image build itself is checked by this PR's CI.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0136P7ZnmBahbhfkFEP6ark4
@coderabbitai

coderabbitai Bot commented Nov 10, 2026 •

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Next included review available in 25 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available.

Learn how review limits work.

Review configuration:

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: ASSERTIVE
  • Plan: Advanced
  • Run ID: c47a42e5-87f7-480f-8ced-c1cb0521df84
Commits

Reviewing files that changed from the base of the PR and between d98b0e2 and b8a6f45.

Files selected for processing: 2

  • .github/workflows/container-ci.yml
  • Containerfile
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

@hyperpolymath
hyperpolymath marked this pull request as ready for review November 10, 2026 18:01
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 10, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ❌ Failed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-10T18:02:37.083100Z 621545c Draft marked ready
🔒 Security Review ❌ Failed 2026-11-10T18:01:26.147199Z
We couldn’t complete this review. Comment @codex security review to try again.
621545c Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector

Copy link
Copy Markdown

This security review couldn’t start because the paying account has exhausted its Codex allowance and has insufficient available credits. The payer can check their balance and add credits in the Codex usage dashboard, then try again. If you do not manage the paying account, contact this repository's admins.

Copy link
Copy Markdown
Owner Author

governance / Validate Hypatia Baseline fails here, but this PR does not cause it.

The check reports 3 findings, in src/rust/provers/test_fixture.rs and src/rust/server/session.rs. The same 3 findings are on main, and this PR does not touch either file. #490 fixes them. When #490 merges, merging main into this branch should clear the check.


Generated by Claude Code

@hyperpolymath
hyperpolymath enabled auto-merge (squash) November 10, 2026 18:09
@sonarqubecloud

Copy link
Copy Markdown

@hyperpolymath
hyperpolymath merged commit c132426 into main Nov 10, 2026
74 of 76 checks passed
@hyperpolymath
hyperpolymath deleted the claude/container-repro-aux-cache branch November 10, 2026 18:16
hyperpolymath added a commit that referenced this pull request Nov 10, 2026
…0.2.0 (#495)

## Summary

`governance / Actions lockfile verify` fails on main (d98b0e2). Every
open PR fails it too, including #490 and #492.

The governance gate installs `gh-actions-lock` v0.2.0. That version
reports unused lockfile entries as errors (upstream
github/gh-actions-lock#159). echidna's lockfile has 8 such entries:

- job-level reusable-workflow calls in `governance`, `hypatia-scan`,
`mirror`, `scorecard`, `secret-scanner`, `security-scan`,
`spark-theatre-gate` and the SLSA publish workflow (standards,
proven-cicd, panic-attack, slsa-github-generator);
- the deleted `boj-build.yml`.

The lockfile does not track reusable workflows. Each one stays
SHA-pinned inline in its workflow file, which `workflow-linter` checks.

## Changes

- `.github/workflows/actions.lock` only. I regenerated it with
`gh-actions-lock` v0.2.0, built from `github/gh-actions-lock` at tag
`v0.2.0`, with `--no-onboard --no-narrow`.
- No workflow file and no step pin changes. A plain `gh actions-lock`
run would also have rewritten 2 bare-SHA pins to refs, one of them to
`@main`. I did not apply those rewrites.

## RSR Quality Checklist

### Required

- [x] No secrets, credentials, or `.env` files included

## Testing

- Before the change: `gh-actions-lock --verify-local` gives "8 of 34
workflows failed: 8 stale", the same entries as the CI failure.
- After the change: "All 34 workflows have complete lockfile coverage."
- The run printed "could not verify" warnings for some pins, because the
tool's GraphQL calls are blocked in this session. Those pins are
unchanged, and the runner re-checks them at job start.

---
_Generated by [Claude
Code](https://claude.ai/code/session_0136P7ZnmBahbhfkFEP6ark4)_

Co-authored-by: Claude <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants