zapty / forever-service

Provision node script as a service via forever, allowing it to automatically start on boot, working across various Linux distros and OS
https://github.com/zapty/forever-service
MIT License
594 stars 65 forks source link

Running with a command and no entry point #67

Closed pjnovas closed 8 years ago

pjnovas commented 8 years ago

Hey there, I have the following start with forever (which works):

sudo forever start -c "npm run start" ./

Can I run that with forever-service?, how do I send the path?

I have tried with no luck:

sudo forever-service install servicename -f " -c npm run start" --start

Which gives the error:

forever-service version 0.5.4

Platform - Ubuntu 14.04.1 LTS
runuserpath not found
app.js not found
arvind-agarwal commented 8 years ago

May be you can try,

sudo forever-service install servicename -f " -c npm run start" -s ./

pjnovas commented 8 years ago

thanks!

light9 commented 7 years ago

You need to add single quotes inside forever arguments: 'npm run start'. Without them I cant get it works. So my solution is: sudo forever-service install servicename -f " -c 'npm run start'" -s ./.

krestaino commented 6 years ago

@light9 That is working for me to install the service and start it, but when I stop the service, the app is still running. Any idea why that might be?