5

I am getting an error while deploying my site

Minimum Node version not met :(

You are using Node v12.22.2. We require Node >=14 or up!

tried updating buildspec.yaml file with node update commands npm install -g node, Buildspec.yaml

3
  • 1
    Can you show the contents of the buildspec file? Commented Nov 5, 2021 at 10:46
  • file added in the question Commented Nov 5, 2021 at 11:09
  • 1
    Did you try using nodejs: latest instead of nodejs: 14.15.1 Also, nodejs version is a child node of runtime-versions:. Hope it is correctly set. Commented Nov 5, 2021 at 12:09

3 Answers 3

4

Try running n 14.18.3.

The n package is pre-installed on (at least some) CodeBuild runtimes which you can use to install another version and select among installed versions.

Details here.

Sign up to request clarification or add additional context in comments.

Comments

4

The default AWS linux container used by CodeBuild only supports nodejs version 12.x, so change it to the ubuntu image aws/codebuild/standard:5.0 that supports node version 14.x

See AWS Available Runtimes for nodejs

Comments

1

It seems that you have spaces in your runtime-versions, it looks like runtime - versions instead of runtime-versions, could it be just this?

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.