Skip to content

Revert "Upgraded node version in docker file"#737

Closed
drizzentic wants to merge 1 commit intomasterfrom
revert-736-node_version_upgrade
Closed

Revert "Upgraded node version in docker file"#737
drizzentic wants to merge 1 commit intomasterfrom
revert-736-node_version_upgrade

Conversation

@drizzentic
Copy link
Copy Markdown
Collaborator

@drizzentic drizzentic commented Mar 12, 2026

Reverts #736

Summary by CodeRabbit

  • Chores
    • Updated build environment configuration to optimize compatibility and build processes.

@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Mar 12, 2026

Walkthrough

The Dockerfile's build stage base image version is downgraded from Node.js 18-alpine to Node.js 14.17-alpine. This single-line change modifies the build environment and associated toolchain, without altering the overall build process or subsequent stages.

Changes

Cohort / File(s) Summary
Build Stage Configuration
Dockerfile
Base image changed from node:18-alpine to node:14.17-alpine in the initial FROM instruction, affecting the Node.js runtime version available during the build stage.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

Possibly related PRs

  • Upgraded node version in docker file #736: Modifies the same Dockerfile build-stage base image version change, but in the opposite direction, indicating a coordinated or conflicting version strategy across related repositories.

Poem

🐰 A rabbit hops through Docker files with glee,
Swapping Node versions, 18 to 14,
The build stage shifts with surgical precision,
Alpine keeps it light—a nimble decision! 📦✨

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately describes the main change: reverting a previous Node version upgrade in the Dockerfile from node:18-alpine back to node:14.17-alpine.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch revert-736-node_version_upgrade

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

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@Dockerfile`:
- Line 2: Update the Docker build base in the Dockerfile by replacing the EOL
image tag on the FROM line (currently "FROM node:14.17-alpine") with a supported
LTS major (e.g., node:20-alpine or node:22-alpine) and rebuild the multi-stage
"build" stage accordingly; then align the CI matrix variable "node-version" in
.github/workflows/master.yml and .github/workflows/tags.yml to the same
supported LTS major (e.g., 20 or 22) so the Docker build and test matrices are
consistent and do not pin to EOL Node versions.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: d1fb235a-7de9-4444-b6eb-0010a6fb0d5f

📥 Commits

Reviewing files that changed from the base of the PR and between e97f156 and 0e9a3d2.

📒 Files selected for processing (1)
  • Dockerfile

@@ -1,5 +1,5 @@
# Build Production Console in Node
FROM node:18-alpine as build
FROM node:14.17-alpine as build
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟠 Major

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "== Node/version declarations in repo =="
fd -HI '^(package(-lock)?\.json|\.nvmrc|\.node-version|Dockerfile)$' \
  -x sh -c 'printf "\n--- %s ---\n" "$1"; sed -n "1,220p" "$1"' sh {}

echo
echo "== CI/workflow references to Node versions =="
rg -n -C2 --glob '**/*.{yml,yaml,json}' '(node-version|setup-node|FROM node:|\"engines\"|lockfileVersion)'

Repository: jembi/openhim-console

Length of output: 11851


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "== CI/Workflow files in repo =="
fd -HI '\.yml$|\.yaml$|ci\.|github' | head -20

echo
echo "== Searching for Node version references in CI files =="
find . -name "*.yml" -o -name "*.yaml" | xargs grep -l "node" 2>/dev/null | head -10

echo
echo "== Content of .github/workflows if exists =="
find .github/workflows -name "*.yml" -o -name "*.yaml" 2>/dev/null | head -5 | xargs cat 2>/dev/null

Repository: jembi/openhim-console

Length of output: 3892


🌐 Web query:

Node.js release schedule LTS timeline Node 14 18 22 end of life dates

💡 Result:

Node.js LTS lifecycle (how the schedule works)

  • New even-numbered majors ship in April, then enter LTS in October, then move to Maintenance LTS, and finally reach End-of-Life (EOL) on a predictable cadence. [1]

LTS timeline & EOL dates (Node 14 / 18 / 22)

Major Codename Initial release LTS starts Maintenance LTS starts EOL
14.x Fermium 2020-04-21 2020-10-27 2021-10-19 2023-04-30
18.x Hydrogen 2022-04-19 2022-10-25 2023-10-18 2025-04-30
22.x Jod 2024-04-24 2024-10-29 2025-10-21 2027-04-30

Sources

  • [1] Node.js Release Working Group — release schedule table (nodejs/Release). (github.com)

Citations:


Avoid reverting the builder to an EOL Node line.

node:14.17-alpine moves the build back to Node 14, which reached End-of-Life on April 30, 2023. Node 18 is also now EOL as of April 30, 2025, so reverting still leaves the build on an unsupported toolchain. The Node.js release guidance recommends production apps use only Active or Maintenance LTS lines.

Additionally, the CI workflows in .github/workflows/master.yml and .github/workflows/tags.yml pin the Docker build matrix to node-version: [14.x], while the test workflow simultaneously tests against 16.x, 18.x, and latest—this inconsistency should be resolved. If PR #736 exposed a compatibility issue, pin to a currently supported LTS major (Node 20 through April 2026, or Node 22 for longer-term stability) instead of reverting to Node 14.

Suggested change
-FROM node:14.17-alpine as build
+FROM node:22-alpine as build
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
FROM node:14.17-alpine as build
FROM node:22-alpine as build
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@Dockerfile` at line 2, Update the Docker build base in the Dockerfile by
replacing the EOL image tag on the FROM line (currently "FROM
node:14.17-alpine") with a supported LTS major (e.g., node:20-alpine or
node:22-alpine) and rebuild the multi-stage "build" stage accordingly; then
align the CI matrix variable "node-version" in .github/workflows/master.yml and
.github/workflows/tags.yml to the same supported LTS major (e.g., 20 or 22) so
the Docker build and test matrices are consistent and do not pin to EOL Node
versions.

@drizzentic drizzentic closed this Mar 12, 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