Skip to content
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

Upgrade to node 18 #1779

Merged
merged 22 commits into from Jul 6, 2023
Merged

Upgrade to node 18 #1779

merged 22 commits into from Jul 6, 2023

Conversation

federicobadini
Copy link
Contributor

@federicobadini federicobadini commented Jun 28, 2023

closes #1756

This PR addresses and closes issue #1756 by standardizing Node.JS to v18 for all environments (development, preview, and production). The upgrade extends to both the frontend and Strapi.

Frontend

We compensated for a change brought in by Node.js 17 that deprioritized ipv4 addresses over ipv6 by introducing the env variable --dns-result-order ipv4first across various commands; see here. Node.JS 17 made this change without introducing a happy-eyeballs implementation, which led to addresses often resolving to the ipv6 loopback address ::1 instead of 127.0.0.1, thus breaking builds. Notably, Node 20 included a happy-eyeballs implementation, and we anticipate being able to remove these env variables in the future.

Strapi

Our current version of Strapi advises the use of Node 18 as per their documentation here. To reflect this, we have updated the backend's package.json to only permit the use of the advised Node.JS versions ("node": ">=14.x.x <=18.x.x") and we updated the Strapi docker base image.

QA

  1. Visit Vercel preview.
  2. Validate that no discernible changes in backend, frontend, or test functionalities are present.

Node.JS 18 is already set as the build image for the react-commerce Vercel project. Please note that react-commerce-prod will also be updated just before this PR is deployed.
So deploy_block 🛑 for the above reason.

@vercel
Copy link

vercel bot commented Jun 28, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
react-commerce ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jul 5, 2023 7:40am
react-commerce-prod ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jul 5, 2023 7:40am

@github-actions
Copy link
Contributor

github-actions bot commented Jun 28, 2023

📦 Next.js Bundle Analysis for @ifixit/commerce-frontend

This analysis was generated by the Next.js Bundle Analysis action. 🤖

This PR introduced no changes to the JavaScript bundle! 🙌

@k0rvusk0r4x
Copy link

All looks well.

QA 😺

@k0rvusk0r4x k0rvusk0r4x removed the QAing Under QA team review label Jul 3, 2023
Copy link
Contributor

@masonmcelvain masonmcelvain left a comment

Choose a reason for hiding this comment

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

CR ✌🏻 With a comment about something I don't understand. Thanks for doing this!

backend/Dockerfile Show resolved Hide resolved
@k0rvusk0r4x k0rvusk0r4x added the QAing Under QA team review label Jul 5, 2023
@k0rvusk0r4x
Copy link

This continue to look good.

QA 😺

@k0rvusk0r4x k0rvusk0r4x removed the QAing Under QA team review label Jul 5, 2023
@erinemay
Copy link
Contributor

erinemay commented Jul 5, 2023

Node.JS 18 is already set as the build image for the react-commerce Vercel project. Please note that react-commerce-prod will also be updated just before this PR is deployed.
So deploy_block 🛑 for the above reason.

deploy_block 🛑 I think deploy blocks in the pull description don't register.

@danielbeardsley
Copy link
Member

un_deploy_block 👍 Looks like react-commerce-prod is already at node 18.

image

Also, the strapi docker image is built and deployed with every relevant merge, so no manual work is needed here.

@danielbeardsley danielbeardsley merged commit f9cc08e into main Jul 6, 2023
15 checks passed
@danielbeardsley danielbeardsley deleted the upgrade-to-node-18 branch July 6, 2023 17:33
@federicobadini federicobadini restored the upgrade-to-node-18 branch July 10, 2023 08:27
@federicobadini federicobadini deleted the upgrade-to-node-18 branch July 10, 2023 08:32
@federicobadini federicobadini restored the upgrade-to-node-18 branch July 10, 2023 08:33
@federicobadini federicobadini deleted the upgrade-to-node-18 branch July 10, 2023 08:35
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.

Upgrade to node 18.x
5 participants