-
Notifications
You must be signed in to change notification settings - Fork 667
[WIP] Update Dockerfile.plugins.demo to use maintained OpenShift CI builder image #15912
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
[WIP] Update Dockerfile.plugins.demo to use maintained OpenShift CI builder image #15912
Conversation
…ilder image Co-Authored-By: Claude Sonnet 4.5
WalkthroughSingle Dockerfile updated to replace base image with nodebuilder, shift build context paths from Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~12 minutes 🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing touches
Comment |
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: sg00dwin The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
🧹 Nitpick comments (2)
Dockerfile.plugins.demo (2)
8-8: PreferCOPYoverADDfor copying local files.Per Dockerfile best practices (and the Hadolint DL3020 rule),
COPYshould be used for copying files and folders from the build context.ADDhas additional capabilities (URL fetching, tar auto-extraction) that aren't needed here and can introduce unexpected behavior.Suggested fix
-ADD . . +COPY . .
29-33: Final stage artifact paths correctly updated.The
COPY --from=nodebuilderinstructions properly reference the new paths from the build stage. Thenode:22base image aligns with the Node.js version in the builder.For CI reproducibility, you might consider pinning to a more specific tag (e.g.,
node:22-slimornode:22.x.y) to avoid unexpected behavior from upstream image updates, though for a demo plugin this is less critical.
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
Cache: Disabled due to data retention organization setting
Knowledge base: Disabled due to data retention organization setting
📒 Files selected for processing (1)
Dockerfile.plugins.demo
🧰 Additional context used
🪛 Hadolint (2.14.0)
Dockerfile.plugins.demo
[error] 8-8: Use COPY instead of ADD for files and folders
(DL3020)
🔇 Additional comments (3)
Dockerfile.plugins.demo (3)
6-6: Good choice using the maintained OpenShift CI builder image.This aligns with the main Dockerfile's base image and ensures consistent tooling (Node.js v22, OpenSSL 3.x) across the console build artifacts. The
rhel-9-base-nodejs-openshift-4.21image is actively maintained by the OpenShift CI team, which should prevent the stale image issues that triggered thebad decrypterrors.
22-26: The path structure changes are correct. The repository root containsfrontend/anddynamic-demo-plugin/directories, and theADD . .at line 8 places them under/opt/app-root/src/(the default WORKDIR for the OpenShift builder base image). The subsequentWORKDIRcommands in lines 22 and 25 correctly navigate to/opt/app-root/src/frontendand/opt/app-root/src/dynamic-demo-plugin. The removal of/consolefrom the path hierarchy reflects the base image layout change, not a misconfiguration—no action needed.
10-20: Yarn bootstrap pattern is sound for this OpenShift builder context.The cached tarball strategy with GitHub fallback is a solid CI optimization.
USER 0is correctly placed here since the OpenShift builder base image requires root for npm operations; the later switch toUSER 1001in the final stage maintains proper non-root production runtime behavior.Two points to ensure consistency:
- The
./artifacts/path is relative to the working directory (/opt/app-root/src). Verify this directory is included in your build context if you intend to leverage tarball caching in CI pipelines.- The v1.22.22 pinning is current (latest Yarn 1.x Classic stable) and avoids the documentation/release discrepancy that exists on the Yarn classic site.
The two-stage build cleanly separates build dependencies from runtime, following K8s container best practices.
|
@sg00dwin: The following tests failed, say
Full PR test history. Your PR dashboard. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here. |
The quay.io/coreos/tectonic-console-builder:v29 image is stale/non-existent
and causes OpenSSL error 1C800066:Provider routines:bad decrypt during
yarn install in CI builds.
Update to use the same rhel-9-base-nodejs-openshift-4.21 base image as
the main Dockerfile, which is actively maintained by the OpenShift CI team
and has proper Node.js v22 + OpenSSL 3.x configuration.
Resolves: console-plugin-demo build failures
Co-Authored-By: Claude Sonnet 4.5
Summary by CodeRabbit
Release Notes
✏️ Tip: You can customize this high-level summary in your review settings.