UPDATE
I uploaded this to Azure and it worked immediately - I believe the issue had something to do with the .env file but I cannot be sure.
So I followed the guide here:
and am trying to push the app to Heroku. I have all my config vars correct - however, when the application launches on heroku I receive:
/app/node_modules/stormpath/lib/ds/RequestExecutor.js:59
npm ERR! VisualVMail#0.0.1 start: `node ./bin/www`
npm ERR! Exit status 8
npm ERR!
npm ERR! Failed at the VisualVMail#0.0.1 start script.
npm ERR! This is most likely a problem with the VisualVMail package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node ./bin/www
npm ERR! You can get their info via:
npm ERR! npm owner ls VisualVMail
npm ERR! There is likely additional logging output above.
npm ERR! System Linux 3.8.11-ec2
npm ERR! command "/app/vendor/node/bin/node" "/app/vendor/node/bin/npm" "st
npm ERR! cwd /app
npm ERR! node -v v0.10.29
npm ERR! npm -v 1.4.14
npm ERR! code ELIFECYCLE
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /app/npm-debug.log
npm ERR! not ok code 0
throw new Error('request.uri field is required.');
Has anyone been able to get Stormpath / nodejs / heroku running, particularly with this sample application?
It looks like you have an issue with the VisualVMail package -- can you try debugging that? It says in the error that request.uri is required.
The error "request.uri field is required" is from the stormpath library. It would be helpful to see the stacktrace, can you look for it in /app/npm-debug.log? It may be in your heroku logs as well.
If, more recently you used the Stormpath automatic add-on - This is an issue with the way Heroku have setup their integrations with Stormpath (or vice-versa). I've sent them a bug report.
In your Heroku Settings > Config Variables; if you have a variable named STORMPATH_URL, remove it and add a new variable called STORMPATH_APPLICATION_HREF with its value as your application's href, e.g. https://api.stormpath.com/v1/applications/<appIDhere>.
Then it should work.
Or in the case of your env file, STORMPATH_APP_HREF should be STORMPATH_APPLICATION_HREF.
Related
I'm trying to deploy my backend application on cpanel and I'm getting an error like this
what should i do to solve this problem?
> test3#0.0.1 start /home/nandaken/inventory
> nest start
stderr:
npm WARN lifecycle The node binary used for scripts is /home/nandaken/nodevenv/inventory/12/bin/node but npm is using /opt/alt/alt-nodejs12/root/usr/bin/node itself. Use the `--scripts-prepend-node-path` option to include the path for the node binary npm was executed with.
sh: nest: command not found
npm ERR! code ELIFECYCLE
npm ERR! syscall spawn
npm ERR! file sh
npm ERR! errno ENOENT
npm ERR! test3#0.0.1 start: `nest start`
npm ERR! spawn ENOENT
npm ERR!
npm ERR! Failed at the test3#0.0.1 start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /home/nandaken/.npm/_logs/2023-01-28T08_16_43_494Z-debug.log
Looks like cpanel is calling the startscript which is running nest start. More than likely, you only have production dependencies installed, so #nestjs/cli isn't installed because it is a devDependency. Either configure cpanel to call a different start script (like start:prod which should map to node dist/main) or change your start script to run the proper js file (like node dist/main). The other option would be to install #nestjs/cli as a production dependency, but I wouldn't suggest that
The system cannot find the path specified.
npm ERR!
code ELIFECYCLE
npm ERR! errno 1
npm ERR! react-able-pro#1.0.0 start: `react-scripts start`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the react-able-pro#1.0.0 start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
ive got some error when i npm start, it always like this when i restart my pc,
ive already use
npm cache clear --force
deleting my modules app and package-lock.jason
npm install
and its doesnt work at all, can you guys help me ?
The library that you are trying to run is "react-able-pro". Through a search on www.npmjs.com for this library, I was not able to find it. However I was able to find react-table-pro.
It looks like a typo. try to fix your package.json file dependencies/devDependencies and then try to reinstall
when i clicked the npm run service. This error is what i am getting
I have used the same app in the following link:
https://github.com/valnub/f7-node-autocomplete-search-demo
framework7-react-app-template#3.0.0 service C:\Users\Tallam Tharun Sai\auto-complete
PORT=3001 nodemon service/service.js
'PORT' is not recognized as an internal or external command,
operable program or batch file.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! framework7-react-app-template#3.0.0 service: `PORT=3001 nodemon service/service.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the framework7-react-app-template#3.0.0 service script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\Tallam Tharun Sai\AppData\Roaming\npm-cache\_logs\2020-07-10T18_16_54_175Z-debug.log
The answer for this is.
I have deleted the Package.json and Node modules from the project and again followed the steps to install the npm as (npm install).
Then I have the installed my npm app successfully.
I am building an app on the Meteor platform, and my app repository is saved on Github. My server is Digital Ocean. I am trying to deploy commits made in Github to my remote server (website) without success. I tried three approaches, outlined below:
1. I tried executing "git pull" in SSH, but after receiving the message " * branch HEAD -> FETCH_HEAD Already up-to-date" the website remained unchanged.
2. I tried running "mupx", which many recommend for use with Meteor, but I received an error message "Verifying deployment: FAILED".
x Verifying deployment: FAILED
-----------------------------------STDERR-----------------------------------
npm#2, which has some small
npm WARN deprecated backwards-incompatible changes made to `npm run-script` and
npm WARN deprecated semver behavior.
npm ERR! install Couldn't read dependencies
npm ERR! Failed to parse json
npm ERR! Unexpected end of input
npm ERR! File: /bundle/bundle/programs/server/package.json
npm ERR! Failed to parse package.json data.
npm ERR! package.json must be actual JSON, not just JavaScript.
npm ERR!
npm ERR! This is not a bug in npm.
npm ERR! Tell the package author to fix their package.json file. JSON.parse
npm ERR! System Linux 3.13.0-43-generic
npm ERR! command "/usr/bin/node" "/usr/bin/npm" "i"
npm ERR! cwd /bundle/bundle/programs/server
npm ERR! node -v v0.10.43
npm ERR! npm -v 1.4.29
npm ERR! file /bundle/bundle/programs/server/package.json
npm ERR! code EJSONPARSE
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /bundle/bundle/programs/server/npm-debug.log
npm ERR! not ok code 0
=> Redeploying previous version of the app
-----------------------------------STDOUT-----------------------------------
To see more logs type 'mup logs --tail=50'
----------------------------------------------------------------------------
3. I even tried doing "git pull" directly into the Digital Ocean server terminal, but once again received the message " * branch HEAD -> FETCH_HEAD, Already up-to-date. ", once again without any updates to the website.
Does anyone know what I may be doing wrong?
Thank you for your time!
I'm trying to learn how to deploy a Node and Angular app to Heroku and am getting an error.
Here are the steps I'm taking
Create an empty repo on GitHub.
Deploy the pre-create project, which creates a new heroku app.
Next, I download and copy the code that is in the pre-created project.
Then I push that code up to the empty repo I created step 1.
I then go back to Heroku and manually deploy connecting my repo to it.
When deploying I get an error that I don't know how to resolve. This is strange to me since I have the pre-configured Heroku app along with the exact same code.
> Building dependencies
Installing node modules (package.json)
> mean-contactlist-angular2#0.0.0 postinstall /tmp/build_00959509bf83606e9586c85b4acd5130/worldofnick-LocalBeats-34154d74169daf6c8cdab1e9e5407bd4e4f9c24e
> ng build
Cannot read property 'config' of null
TypeError: Cannot read property 'config' of null
at Class.run (/tmp/build_00959509bf83606e9586c85b4acd5130/worldofnick-LocalBeats-34154d74169daf6c8cdab1e9e5407bd4e4f9c24e/node_modules/#angular/cli/tasks/build.js:16:56)
at Class.run (/tmp/build_00959509bf83606e9586c85b4acd5130/worldofnick-LocalBeats-34154d74169daf6c8cdab1e9e5407bd4e4f9c24e/node_modules/#angular/cli/commands/build.js:143:26)
at Class.<anonymous> (/tmp/build_00959509bf83606e9586c85b4acd5130/worldofnick-LocalBeats-34154d74169daf6c8cdab1e9e5407bd4e4f9c24e/node_modules/#angular/cli/ember-cli/lib/models/command.js:134:17)
at process._tickCallback (internal/process/next_tick.js:109:7)
npm ERR! Linux 3.13.0-133-generic
npm ERR! argv "/tmp/build_00959509bf83606e9586c85b4acd5130/worldofnick-LocalBeats-34154d74169daf6c8cdab1e9e5407bd4e4f9c24e/.heroku/node/bin/node" "/tmp/build_00959509bf83606e9586c85b4acd5130/worldofnick-LocalBeats-34154d74169daf6c8cdab1e9e5407bd4e4f9c24e/.heroku/node/bin/npm" "install" "--unsafe-perm" "--userconfig" "/tmp/build_00959509bf83606e9586c85b4acd5130/worldofnick-LocalBeats-34154d74169daf6c8cdab1e9e5407bd4e4f9c24e/.npmrc"
npm ERR! node v6.11.5
npm ERR! npm v3.10.10
npm ERR! code ELIFECYCLE
npm ERR! mean-contactlist-angular2#0.0.0 postinstall: `ng build`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the mean-contactlist-angular2#0.0.0 postinstall script 'ng build'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the mean-contactlist-angular2 package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! ng build
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs mean-contactlist-angular2
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls mean-contactlist-angular2
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! /tmp/build_00959509bf83606e9586c85b4acd5130/worldofnick-LocalBeats-34154d74169daf6c8cdab1e9e5407bd4e4f9c24e/npm-debug.log
-----> Build failed
We're sorry this build is failing! You can troubleshoot common issues here:
https://devcenter.heroku.com/articles/troubleshooting-node-deploys
Some possible problems:
- Node version not specified in package.json
https://devcenter.heroku.com/articles/nodejs-support#specifying-a-node-js-version
Love,
Heroku
! Push rejected, failed to compile Node.js app.
! Push failed
I ran into this problem while deploying to Heroku today. In your package.json, make sure you are correctly specifying node as your engine. Example:
"engines": {
"node": "^8.0.0"
},