Trying to deploy a Node.js application to heroku but when using
git push heroku master
I get the following trace (only part of the whole trace is shown but it is the part which I believe to be the problem - if not let me know):
remote: -----> Build failed
remote:
remote: We're sorry this build is failing! You can troubleshoot common issues here:
remote: https://devcenter.heroku.com/articles/troubleshooting-node-deploys
remote:
remote: Some possible problems:
remote:
remote: - Dangerous semver range (>) in engines.node
remote: https://devcenter.heroku.com/articles/nodejs-support#specifying-a-node-js-version
remote:
remote: Love,
remote: Heroku
remote:
remote:
remote: ! Push rejected, failed to compile Node.js app
The package.json file works fine with other people's heroku, so that doesn't seem to be the problem.
Any ideas let me know.
Thanks
The issue is caused because you are trying to push with node version greater or less than what you installed. Do node -v
then replace the value of your installed node version with the one in your package.json.
https://devcenter.heroku.com/articles/nodejs-support#specifying-a-node-js-version
redo a
git add .
git commit -a -m'comment'
git push
plz ref
heroku push rejected failed to compile node.js app
Push rejected, failed to compile Node.js app heroku
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With