Skip to content

chore(publish): pin docker base image refs#4652

Merged
NathanFlurry merged 1 commit intomainfrom
04-14-chore_publish_pin_docker_base_image_refs
Apr 24, 2026
Merged

chore(publish): pin docker base image refs#4652
NathanFlurry merged 1 commit intomainfrom
04-14-chore_publish_pin_docker_base_image_refs

Conversation

@NathanFlurry
Copy link
Copy Markdown
Member

Description

Please include a summary of the changes and the related issue. Please also include relevant motivation and context.

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

How Has This Been Tested?

Please describe the tests that you ran to verify your changes.

Checklist:

  • My code follows the style guidelines of this project
  • I have performed a self-review of my code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes

@NathanFlurry NathanFlurry mentioned this pull request Apr 14, 2026
11 tasks
@railway-app
Copy link
Copy Markdown

railway-app Bot commented Apr 14, 2026

🚅 Deployed to the rivet-pr-4652 environment in rivet-frontend

Service Status Web Updated (UTC)
kitchen-sink ❌ Build Failed (View Logs) Web Apr 24, 2026 at 7:34 am
website 😴 Sleeping (View Logs) Web Apr 23, 2026 at 11:36 pm
ladle ❌ Build Failed (View Logs) Web Apr 14, 2026 at 9:35 pm
frontend-cloud ❌ Build Failed (View Logs) Web Apr 14, 2026 at 9:35 pm
frontend-inspector ❌ Build Failed (View Logs) Web Apr 14, 2026 at 9:35 pm
mcp-hub ✅ Success (View Logs) Web Apr 14, 2026 at 9:34 pm

Copy link
Copy Markdown
Member Author

NathanFlurry commented Apr 14, 2026

This stack of pull requests is managed by Graphite. Learn more about stacking.

@NathanFlurry NathanFlurry changed the base branch from 04-14-break_this_up_wip_patches to graphite-base/4652 April 14, 2026 21:59
@NathanFlurry NathanFlurry force-pushed the 04-14-chore_publish_pin_docker_base_image_refs branch from 15a3f42 to e990012 Compare April 14, 2026 21:59
@NathanFlurry NathanFlurry changed the base branch from graphite-base/4652 to 04-14-chore_engine_publish_engine_bases_in_ci April 14, 2026 21:59
@railway-app railway-app Bot temporarily deployed to rivet-frontend / rivet-pr-4652 April 14, 2026 21:59 Destroyed
@NathanFlurry NathanFlurry force-pushed the 04-14-chore_publish_pin_docker_base_image_refs branch from e990012 to ee14c1d Compare April 14, 2026 22:03
@railway-app railway-app Bot temporarily deployed to rivet-frontend / rivet-pr-4652 April 14, 2026 22:03 Destroyed
@claude
Copy link
Copy Markdown

claude Bot commented Apr 14, 2026

PR #4652 Review: chore(publish): pin docker base image refs

Overview

This PR changes how Docker base image tags are managed for CI builds:

  1. Pins base image tags directly in Dockerfiles instead of passing them as build args from the CI environment.
  2. Removes the engine-base-images CI job that published engine-specific base images per commit SHA -- engine bases are now also statically pinned.
  3. Automates tag pinning in build-push.sh via a new pin_consumer_dockerfiles() function that updates all Dockerfiles on ./scripts/docker-builder-base/build-push.sh all --push.

Bug: engine-slim pattern is missing the stage alias

The update_from_line call for engine-base-runtime-slim in build-push.sh is inconsistent with the other engine calls -- it omits the AS engine-slim alias in both the grep pattern and the replacement.

The actual Dockerfile line is:

FROM ghcr.io/rivet-dev/rivet/engine-base-runtime-slim:a36b881 AS engine-slim

The grep check uses pattern ^FROM .*/engine-base-runtime-slim:[^[:space:]]+$ with end-of-line anchor. This fails to match because [^[:space:]]+ stops at the tag, leaving AS engine-slim unmatched before the $ anchor. By contrast, the engine-builder and engine-full calls correctly include the stage alias (AS builder, AS engine-full-base) in both pattern and replacement -- engine-slim inconsistently omits it.

The next run of ./scripts/docker-builder-base/build-push.sh all --push will error on this step and leave the engine Dockerfile partially updated.

Fix -- add the alias to both pattern and replacement for the slim stage.


CLAUDE.md is now stale

CLAUDE.md currently says:

Rebuild publish base images with scripts/docker-builder-base/build-push.sh <base-name|all> --push; update BASE_TAG when rebuilding shared builder bases, while engine bases are published per commit in publish.yaml.

Both instructions are outdated: BASE_TAG no longer exists, and engine bases are no longer published per commit. Should update to reflect the new flow (run all --push, the script auto-pins the Dockerfiles).


Minor observations

  • Differing tags between builder and engine bases (0e33ceb98 vs a36b881) is expected since they have independent publish cadences, but a comment explaining the distinction would help future contributors.
  • pin_consumer_dockerfiles cannot be called standalone -- it only runs on all --push, so rebuilding a single base still requires manually updating the Dockerfile. The updated end-of-script message communicates this adequately.

Summary

The core approach (pinning directly in Dockerfiles, automating updates via script) is a clear improvement over the previous env-var approach. The engine-slim alias mismatch is a real bug that will break the next all --push run and should be fixed before merge.

@NathanFlurry NathanFlurry force-pushed the 04-14-chore_engine_publish_engine_bases_in_ci branch from 544febb to cb832d4 Compare April 24, 2026 07:33
@NathanFlurry NathanFlurry force-pushed the 04-14-chore_publish_pin_docker_base_image_refs branch from 3327c8c to 9e923ab Compare April 24, 2026 07:33
@railway-app railway-app Bot temporarily deployed to rivet-frontend / rivet-pr-4652 April 24, 2026 07:33 Destroyed
@railway-app railway-app Bot temporarily deployed to rivet-frontend / production April 24, 2026 07:38 Inactive
Base automatically changed from 04-14-chore_engine_publish_engine_bases_in_ci to main April 24, 2026 07:39
@NathanFlurry NathanFlurry merged commit 9e923ab into main Apr 24, 2026
22 of 33 checks passed
@NathanFlurry NathanFlurry deleted the 04-14-chore_publish_pin_docker_base_image_refs branch April 24, 2026 07:39
This was referenced Apr 24, 2026
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.

1 participant