Questions tagged [forever]
Forever is a Node.js package that ensures a script continues to run. Do not use this tag for everlasting conditions, loops, animations, …
621
questions
0
votes
1answer
20 views
How to move the nodejs files to the server using forever?
I am new to Node.js as I am trying to move the Node.js files to a server using forever.
I have created the Node.js files using npm i express-generator so when I use nodemon it is starting like this:
...
0
votes
0answers
18 views
how to run spring boot jar using forever
My application jar package is ready. i can start application using below.
java -jar myapp.jar &
is forever run this spring boot application.?
forever java -jar myapp.jar
0
votes
0answers
30 views
Keep Kotlin console application running forever
I have an event driven Kotlin console application utilizing the Paho MQTT client.
I successfully connect via
val serverURI = "${config.mqtt.protocol}://${config.mqtt.host}:${config.mqtt.port}&...
0
votes
0answers
13 views
How to run react production build with forever
I created a react app which I want to set my browser's homepage.
I got to know that I can use forever for this but don't know how to use it for this purpose.
How can I run the production build using ...
0
votes
0answers
12 views
execute forever python3 project
I need to run a forever command for python3 project but I can only run the command below in linux:
forever-service install -s server.py,
but the project runs using python2, does anyone know what ...
0
votes
0answers
49 views
Nodemon not killing Node before trying to restart EEADINUSE error
this is my first node.js server.
I have created the server.js and it is running.
I installed nodemon and have it running and I also installed forever and got them running together.
Every time I make a ...
0
votes
0answers
44 views
Cannot start json-server with forever on ubuntu
I am using below command to start json-server forever on my ubuntu:
forever start /usr/local/bin/json-server --watch db.json --port 3001
But as I list all processes using forever list, I see that the ...
0
votes
2answers
45 views
So I want to restart nodejs server at crash
So I want to restart nodejs server at crash. I run scripts with this command.
nodemon -r esm app.js
I tried with forever but somehow not able to find the right command to pack "nodemon -r esm ...
0
votes
0answers
17 views
How do I stop my node app after using forever to start it
I'm running my nextjs app with forever like this:
forever start -c "npm start" ./
that works great for starting it, but I have found no way of stopping it. If I kill the process, the app ...
1
vote
0answers
166 views
Forever: SyntaxError: Invalid or unexpected token
I am deploying a simple node js web application. Everything is working fine until the point I wanted to keep it running by using the forever command. I am able to run without any problem by typing ...
0
votes
0answers
16 views
start node application with forever on reboot
I'm trying to make my application start on reboot.
I'm using bitnami's node.js image(12.18.3) over AWS.
I wrote a simple script start.sh that gets uid and executes:
/opt/bitnami/node/bin/forever start ...
0
votes
1answer
25 views
NodeJS forever after @reboot
I am working with React and need my web page to be alive after reboot.
So I need forever after crontab.
What I have tried.
crontab -e
@reboot ~/reboot.sh
@reboot sudo service nginx restart
#!/bin/...
0
votes
0answers
29 views
Does a node app work after I hibernate my laptop
I use forever npm to run my node apps. I executed: "forever start index.js" and left VSCode. I hibernated the computer then. I didn't have a 2nd device to test if my node app still works. ...
0
votes
3answers
90 views
Node JS with async unexpected infinite loop
I have a JS file that repeats itself automatically only when an error is expected dues to a timeout such as:
website not reachable -> timeout to be reached
tag looked for in the "waitSelector&...
1
vote
0answers
13 views
How to provide relative path for log files in Node forever
I am using forever to start a node.js application using the following command:
forever start -l /<fullpath to my folder>/logs/forever_log.log -a server.js
If I run it as:
forever start -l ...
0
votes
0answers
20 views
Unable to start forever service
I am running following command to run my forever but its not starting:
sudo NODE_ENV=dev forever start /home/centos/abc/staging_app/Server.js
OR
sudo NODE_ENV=dev forever start --uid "r9b8" -...
0
votes
0answers
154 views
forever command not found when ran in sudo
I installed forever in centos with
sudo npm install forever -g
i can run forever normally with
forever list
but when i run the same with
sudo forever list
it gives me this error
forever command not ...
0
votes
0answers
17 views
How can I see the error log in forever.js?
I'm started using forever for my script. I run this code
sudo forever start -l forever.log -e err.log index.js
Now when I check forever logs, I see that the log is stored in forever.log. So it's ...
0
votes
0answers
44 views
How can I automatically restart console diagram app written with Blessed contrib?
I have a nodejs script that I use to build diagrams in console (using https://github.com/yaronn/blessed-contrib library) with my actual data that I fetch from API.
I need a way to automatically ...
0
votes
0answers
79 views
forever node process not working in background
i want to start process in background with forever node package, right now manually i am using this command yarn start:server, i want to run this command in background with forever npm package, for ...
0
votes
0answers
29 views
How to programmatically check if console.log output is currently being written to a file or to Chrome Dev Tools console?
This is a peculiar setup. I have node running using forever with the --inspect arg and I use console.log() to log information into both a file AND to the Chrome Dev Tools console:
forever start -a -l ~...
0
votes
0answers
49 views
How can I execute a Windows batch file from Node.js forever?
I'm running Windows 10, and I would like to execute a Windows .bat script from forever (v3.0.0)
forever is installed globally and working fine, and I have successfully used to start other applications....
0
votes
1answer
22 views
forever is not working as expected after closing terminal or console
I have installed forever on shared hosting Cpanel for node js application when I run forever start app.js, node js application works on the server.
warn: --minUptime not set. Defaulting to: 1000ms
...
0
votes
0answers
10 views
Node GC execution value is different, although server and not configeration is same
I have two machines, with the same configuration:
2 core; 8 GB RAM.
Ubuntu 14.04; Kernel 3.13.0-92-generic
Both having Node: v6.10.3; and the processes are running with v0.15.3.
Both the node ...
0
votes
0answers
22 views
Nginx gives 502 Bad Request if Forever starts the Node app with full path
I use nginx and have a node.js app, which is started by forever.
If I manually cd into my app folder and start the app with forever start index.js it works.
BUT if I start the app with forever start ...
0
votes
1answer
23 views
Start forever using bash if it is not executing
I have a socket application, which is created in node js. I was using forever to run this application. Due to some reason, forever is stopping automatically. I have created a script to check the port ...
0
votes
1answer
60 views
Forever tool with mosquitto mqtt
I'm trying to make my mosquitto mqtt broker run constantly on my cloud instance with the forever tool using forever start -l mqtt.log --append -c -sh /root/mqtt-sh.sh and I already created the shell ...
4
votes
3answers
710 views
how to use forever with npm
i am trying to run this command in my debian 10 vps forever start npm start but i got this error in the terminal,
warn: --minUptime not set. Defaulting to: 1000ms
warn: --spinSleepTime not set....
3
votes
1answer
1k views
How to run nodemon + forever in the background
Good morning!
I need my node.js server running in the background. I just saw this answer: Forever + Nodemon running together
I understand the idea, and I think that it's great, but when I use
...
0
votes
1answer
20 views
How to have foreverjs persist after logout?
This article ([1]) shows how to use foreverjs with authbind, but it is not clear to me whether or not the forever process will persist after logging out.
Is there an easy way to get foreverjs to ...
0
votes
0answers
101 views
How to Configure PM2 or Forever packages with a Express-Nuxt Project
So i have a small blogger Web Application made with Express and Nuxt which is running well, but i couldn't find any way to bind one of those packages (Forever/PM2) with it,
nuxt automatically sets the ...
1
vote
0answers
39 views
Angular 6 ng serve failing after sometime in production
I m new to Angular. I have created Angular 6 application.
Angular CLI: 6.2.1
Node: 10.16.0
Angular: 6.1.0
Started the application using command:
ng serve --ssl --host 0.0.0.0
It runs but after ...
0
votes
0answers
55 views
Angular 6 ng serve is stopped after sometime
I have front end UI developed using angular 6. Starting the app using cmd
"ng serve --ssl --host 0.0.0.0"
.
Application started but after some time it stopped. How can we keep angular 6 running ...
0
votes
1answer
44 views
How to make my server available with “forever start server.js”
I have spent multiple hours to try and get my server up and running. As a part of a class assignment we are migrating to ExpressJS. So the instruction go as follows:
Install latest version of nodejs ...
-1
votes
2answers
60 views
Restart a meteor js application process (forever process) on server reboot
I'm currently working on an application developed with meteor.js framework and database as nosql (mongodb). The application is hosted on a Linux server. We currently have an issue wherein on ...
0
votes
0answers
34 views
Suppress HTTP logging in Sails.js [duplicate]
I'm running a Sails v1 web app as a service in production on port 80 like so (don't know if it's the correct way since I couldn't find any precise directive in the docs):
sudo NODE_ENV=production ...
0
votes
2answers
204 views
How do you run a NodeJS Express API with typescript files with Forever?
I have npm installed forever, also npm installed ts-node, and npm installed typescript to try and get this API running.
I have been trying " forever start -v -c ts-node ./lib/server.ts" or "forever ...
0
votes
2answers
163 views
How to serve a Nodejs & Express app using Phusion Passanger
I have a node & express app that is currently hosted on a shared hosting. I would like to run and manage the app using Phusion Passenger. My hosting account supports nodejs applications managed by ...
0
votes
0answers
52 views
Why Forever killed by SIGKILL?
error: Forever detected script was killed by signal: SIGKILL
Running Node project on linux (EC2)
This happens second time in the production mode. At this time need to manual restart. Why the forever ...
0
votes
0answers
34 views
nodejs forever module on windows
I installed forever / forever-win globally on windows. But running a nodejs script by:
"forever start script.js" doesn't run the script. "forever list" just gives:
gNTx "C:\Program Files\nodejs\node....
1
vote
1answer
86 views
Start and stop npm from PHP script
OK, a silly question. Is it possible to do start npm from a PHP script, via the browser? For example, by doing something like this?
// start.php
echo exec('npm run forever');
die();
And then, to ...
3
votes
1answer
2k views
Redis Error “max number of clients reached”
I am running a nodeJS application using forever npm module.
Node application also connects to Redis DB for cache check. Quite often the API stops working with the following error on the forever log. ...
0
votes
0answers
34 views
What is the best way for a development NodeJS docker container to watch filesystem changes and restart on crash?
Given a dockerized NodeJS based app, what it the best way to fullfill the following needs:
To restart automatically the NodeJS app on a change in the source
code
To restart automatically the NodeJS ...
0
votes
1answer
42 views
How to stop forever from retrying?
I have a nodejs server. I use forever to start the server using the following batch script:
c:\
cd c:\somefolder
forever start server.js
sleep 10
pause
The issue is if the server fails to start ...
0
votes
0answers
126 views
'C:\Program' is not recognized as an internal or external command, This issue arrives everytime when i try to run Forever Node Module
I'm using this command- forever start --minUptime 1000 --spinSleepTime 1000 ./bin/www
'C:\Program' is not recognized as an internal or external command - This error appears in logs everytime(C:\Users\...
0
votes
0answers
180 views
Forever package issue in node js backend
Previously I had nodemon but it was not working properly So I have installed Forever package to keep updating my server files after changes. But it keeps crashing and I don't know reason b'z I am new ...
0
votes
1answer
272 views
How to run sh script from node.js project?
My sh script suddenly closes. I'm trying to control sh process by another script.
Nohup doesn't help me so I decided to use my Node.js working on forever. So I have found child_process lib but doesn't ...
1
vote
2answers
1k views
Error running forever.js on Windows - “'C:\Program' is not recognized as an internal or external command, operable program or batch file”
I am trying to run forever.js via the Windows command prompt and I get the following output:
>npm i -g forever
/my-project>forever start index.js
Log output:
'C:\Program' is not recognized ...
0
votes
1answer
465 views
How to start Jenkins with a different user?
I am working with Jenkins and I want to start a script with forever using Jenkins with a different user named aroot.
So my build configuration I write this command:
sudo -u aroot forever start -a --...
0
votes
1answer
206 views
DockerFile: on container stop. Run commands on stop signal
I have a process that runs in the background of my docker contained website. I am currently using forever npm package to keep this running.
I would like to clean up the process cleanly when the ...