Keep laravel-echo-server running even if I close terminal
Hello, as the title of this new discussion, how do I keep laravel-echo-server running even if I close the terminal. I'm using Forge and Digital Ocean.
Thanks in advance!
You can use PM2 to manage and provision Node.js processes. there is also forever.
@logaretm I installed PM2 and run
pm2 start laravel-echo-server
It started but couldn't connect to the server from the frontend.
Did I miss something?
I'm not sure, but you should install it globally with sudo privileges otherwise it won't be able to maintain the process.
sudo npm install -g pm2
you can also run
pm2 list to check if the process is running, if it is running then probably the problem is elsewhere. sorry I couldn't help more.
It's started server but can't connect on front end...
@hdsavani do you find solution yet?
i notice it work only when we run laravel-echo-server start
but it not serve on background
when I use pm2 start laravel-echo-server
but I think it not start properly
Please or to participate in this conversation.