niutech / node.php

Run node.js apps from PHP even on a shared hosting!
819 stars 235 forks source link

etherpad-lite what am I missing #43

Open ThorsenRune opened 3 years ago

ThorsenRune commented 3 years ago

Hi, thanks for a great project. I would like to try etherpad-lite so I ran this php on my localhost. However I can't seem to get past http://localhost/..../test/node.php?path=node_modules\ep_etherpad-lite\node\server.js Error requesting node_modules\ep_etherpad-lite\node\server.js: Failed to connect to 127.0.0.1 port 9001: Connection refused neither with the default 49999 nor with 9001 as portnumber which I believe is requested by etherpad. What am I missing? Thanks

Zono4ever commented 3 years ago

Hi there,

I#ve playaround with this code for fews year ago. And sometime I get this error too. In my code I've create a text file that will auto insert every port that I've created while starting the code, so I can know exactly which ports are running. So you need to kill all the port that still running or change to a new port. And than just restart you code this will work. If you have the same error with other module that u try to install just do the same think!!!

Why you get this error. example you starting u code on port 9001 and u try to do somethink with your code and get crash. The code need to restart but sometime the port 9001 don't exit with the code by self and is still running. So you try to restart your code in the same port 9001. But the port 9001 already running so the code get confused. That's why you need too kill the port!!! Just type "killnode all" in you terminal and everythink is fine!!!

SORRY FOR MY BAD ENGLISH AND HOPE U STILL UNDERSTAND :D !!!!

Good luck!