• Please be aware: Kaspersky Anti-Virus has been deprecated
    With the upgrade to Plesk Obsidian 18.0.64, "Kaspersky Anti-Virus for Servers" will be automatically removed from the servers it is installed on. We recommend that you migrate to Sophos Anti-Virus for Servers.
  • The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.
  • We’re working on enhancing the Monitoring feature in Plesk, and we could really use your expertise! If you’re open to sharing your experiences with server and website monitoring or providing feedback, we’d love to have a one-hour online meeting with you.

Question How does node work on plesk?

MarioSmith91

New Pleskian
Greetings,

I wrote an application in node that uses a web server node set on port 3000 on this web server I created a client-side GUI (fontEnd) that allows you to do some operations such as:

- CLICK A BUTTON 'Start program number 2'
- CLICK A BUTTON 'Stop program number 2'
- Change program settings

When you click on Start program number 2 the web server sends via ajax (with the POST method) a variable to the webServer.js script which in turn triggers a function
which starts another script node (prog2.js) via the spawn method which starts a child_process, all console.log and program outputs (prog2.js) are redirected to weServer.js
via the node socket.io module. All this works perfectly if I activate node via SSH and connect to the ip of my Ex server:

- 111.111.111.111:3000


If, on the other hand, I use the domain that I set from Plesk and I activate node from the domain extension on Plesk through the Plesk nod js extension, Ex:

- mydomain.com

With port 3000 (mydomain.com:3000) it doesn't work, but it works if I just put the domain without port (mydomain.com), so it's as if Plesk set the basic web port directly

that is the 80, moreover if I try to click the button 'Start program number 2' I do not receive the redirection of the output of the second script, so I believe that I can not even

start the child_process.

Why does he do this? How does the Plesk node work? How can I get a console so I can understand what's going on? Where can I find documentation on how Plesk works on node?


Thank you in advance for your availability.


PS
Please enlighten me :)
 
Back
Top