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

render.com errors with astrojs/react #6004

Closed
1 task
ngmisl opened this issue Jan 27, 2023 · 2 comments
Closed
1 task

render.com errors with astrojs/react #6004

ngmisl opened this issue Jan 27, 2023 · 2 comments

Comments

@ngmisl
Copy link

ngmisl commented Jan 27, 2023

What version of astro are you using?

2.0.1

Are you using an SSR adapter? If so, which one?

render.com

What package manager are you using?

yarn

What operating system are you using?

linux

Describe the Bug

trying to deploy to render.com from github, getting

tried to deploy to render, got Jan 27 09:22:33 AM error @astrojs/react@2.0.0: The engine "node" is incompatible with this module. Expected version ">=16.12.0". Got "14.20.0"

Link to Minimal Reproducible Example

https://docs.astro.build/en/guides/deploy/render/#how-to-deploy

Participation

  • I am willing to submit a pull request for this issue.
@HiDeoo
Copy link
Member

HiDeoo commented Jan 27, 2023

Since astro@2.0.0, the minimum supported Node version is >=16.12.0. By default, Render uses Node version 14.

There are 4 ways to customize this on Render detailed here:

  • A NODE_VERSION environment variable
  • A .node-version file
  • A .nvmrc file
  • An engines section in your package.json

I managed to repro your issue during a deploy on Render without specifying any version and confirmed that adding a .node-version version file at the root of the repo containing 16.12.0 fixes the issue.


As Render is still using Node version 14 by default, I wonder if it could be worth documenting this until they update the default version in https://docs.astro.build/en/guides/deploy/render/#how-to-deploy ?

@ngmisl
Copy link
Author

ngmisl commented Jan 27, 2023

that did it, thanks!

@HiDeoo agreed, this should be mentioned in the docs please

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

No branches or pull requests

2 participants