Node deploy failed

I’m trying to deploy a server that one time it was success and then it’s only rejected :frowning:

The same commit giving me multiple random errors and before the only time it success deploying:


It has another commit but i did not change something important or relevant.

I’m using yarn for build and npm start for starting the project, and i’m not using healthy.

Am i doing something wrong or why is this random?

Here i left a ss of the last deploy failed:

And now i’m deploying the same commit that worked before and it failed (fb674f5):

Sorry for multiple replies but i can’t upload twice images in the same reply, this is the last reply :sweat_smile:

Hi there,

Thanks for reaching out.

You should first try and match your local environment as close as possible, for example:

  • Match your local/development package manager in the Build Command. If you use yarn locally, use that on Render. Or swap it for npm if that’s your chosen manager. Mixing them, as you noted above, probably isn’t ideal.

  • Still around the Build Command; maybe your project needs building for production? e.g. a Build Command of npm install; npm run build;

  • Match your local/development Node version. This can be set in various ways, more in docs: Specifying a Node Version

If all those are set as you used in development, and you’re still having issues, please share the service name/ID and we can take a closer look.

Kind regards

Alan

Thanks for reply Alan!

I used npm install and npm run start because that’s all i need to run the project, i’m using a newest node version so i set the environment variable NODE_VERSION = 16.14.2 and i still have issues deploying the app, gonna send to you in PM the service ID.

Any help about this :pray: ?

16.14.2 isn’t the newest version of Node. 18.12.1 is current LTS and 19.0.1 is the latest. You should be matching what you developed on to keep differences to a minimum. Can you try a manual deploy clearing the build cache?

Alan

Hi,
I have latest version of nodejs but still getting same error.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.