updating dockerfile for go 1.26 and ubi 10#128
updating dockerfile for go 1.26 and ubi 10#128acornett21 merged 1 commit intoredhat-openshift-ecosystem:mainfrom
Conversation
Signed-off-by: Adam D. Cornett <adc@redhat.com>
WalkthroughDockerfile base images are updated to newer versions: the builder stage now uses golang:1.26 (previously 1.25) and the runtime stage uses ubi10/ubi-micro:latest (previously ubi9/ubi-micro:latest). Build and runtime flow remain functionally unchanged. ChangesDockerfile Base Image Updates
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~3 minutes 🚥 Pre-merge checks | ✅ 6 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (6 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
🧹 Nitpick comments (1)
Dockerfile (1)
18-18: ⚡ Quick winPin the runtime base image to a digest instead of
:latest.The
ubi10/ubi-micro:latesttag is mutable and can change between builds, causing non-deterministic rebuilds and unexpected runtime changes. Red Hat's guidance recommends pinning images by immutable digest for production reproducibility. Retrieve the digest usingskopeo inspect --format 'Digest: {{.Digest}}' docker://registry.access.redhat.com/ubi10/ubi-micro:latest(orpodmanequivalent), then pin it in the Dockerfile:Suggested change
-FROM registry.access.redhat.com/ubi10/ubi-micro:latest +ARG UBI_MICRO_IMAGE=registry.access.redhat.com/ubi10/ubi-micro@sha256:<retrieved_digest> +FROM ${UBI_MICRO_IMAGE}🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@Dockerfile` at line 18, The Dockerfile currently uses a mutable image tag in the FROM line ("registry.access.redhat.com/ubi10/ubi-micro:latest"); replace that tag with the image's immutable digest by running a tooling command such as "skopeo inspect" or "podman inspect" to obtain the digest (e.g., Digest: sha256:...) and update the FROM to "registry.access.redhat.com/ubi10/ubi-micro@sha256:<digest>" so builds are deterministic and reproducible.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Nitpick comments:
In `@Dockerfile`:
- Line 18: The Dockerfile currently uses a mutable image tag in the FROM line
("registry.access.redhat.com/ubi10/ubi-micro:latest"); replace that tag with the
image's immutable digest by running a tooling command such as "skopeo inspect"
or "podman inspect" to obtain the digest (e.g., Digest: sha256:...) and update
the FROM to "registry.access.redhat.com/ubi10/ubi-micro@sha256:<digest>" so
builds are deterministic and reproducible.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Enterprise
Run ID: cfa5982c-60b4-45bc-b07c-1498e27b38a9
📒 Files selected for processing (1)
Dockerfile
Summary by CodeRabbit