12:22:23 PM: Failed during stage 'building site': Build script returned non-zero exit code: 2 (https://ntl.fyi/exit-code-2) Command failed with exit code 1: CI= npm run build

Yeah the build was successful but I’m getting this error when I’m trying to access the link:

Page Not Found

Looks like you’ve followed a broken link or entered a URL that doesn’t exist on this site.

Back to our site


If this is your site, and you weren’t expecting a 404 for this path, please visit Netlify’s “page not found” support guide for troubleshooting tips.

One thing I would like to add that it’s a MERN Stack application and the backend is the main directory and the frontend is in the frontend folder