I tried to deploy react based web app but i got this errors

10:38:33 AM: “build.command” failed
10:38:33 AM: ────────────────────────────────────────────────────────────────
10:38:33 AM: ​
10:38:33 AM: Error message
10:38:33 AM: Command failed with exit code 1: npm run build (Search results for '"non-zero exit code: 1"' - Netlify Support Forums)
10:38:33 AM: ​
10:38:33 AM: Error location
10:38:33 AM: In Build command from Netlify app:
10:38:33 AM: npm run build
10:38:33 AM: ​
10:38:33 AM: Resolved config
10:38:33 AM: build:
10:38:33 AM: command: npm run build
10:38:33 AM: commandOrigin: ui
10:38:33 AM: publish: /opt/build/repo/build
10:38:33 AM: publishOrigin: ui

@dawit2001 Can you supply the entire build log?

The portion that you’ve provided shows that the build failed when executing npm run build, but it doesn’t contain the portion that would reveal “why it failed”.

Would you mind sharing your site name please?

Have you looked through this resource? It is a compilation of all of our build and deploy resources. This is a good starting point.

If you have worked through those guides and are still encountering issues please share the following information:

  • what you have already tried
  • any error messages you have received in your terminal window or in the developer console