25

Add NodeJS support

  • Live

Avatar
Jo Hannes

Please Support Nodejs App For Future

A

Activity Newest / Oldest

Avatar

Dennis

So now this is live, I'd accept any new feature request cards for this feature if you have any.


Avatar

Dennis

Status changed to: Live

N

Nathan Reed

Great work Dennis, this will be an amazing feature!


  • Avatar
  • P
Avatar

Dennis

Ok I can't help it: last tease video before release👀

Hoping to release around Friday, maybe sooner!

screenshot.webbuilds.nl/yx0SDTLvOdWGiPcjVm4o


  • Avatar
  • P
P

philipp

While this is amazing, I found a beautiful bug in here: Pressing the heart on a comment while logged out, logging in is giving that heart to each comment in the discussion. So I finally gave much more love than intended… In this case better more than less. 😉


  • Avatar
Avatar

Dennis

Haha 🤣 Unrelated to this roadmap item, but I will pass this along to the makers of this piece of software!


Avatar

theraloss

Haha that's true, I just noticed all my upvotes here, oops. Anyway Dennis, great job! Will Ploi take care of all the NGINX configuration like he does for Laravel?


  • Avatar
Avatar

Dennis

Yes, it does! There's no need to do any NGINX customization. The only important things you need to configure is the start command and the port the server is running on!


  • Avatar
Avatar

Dennis

Small tease video here 😎😎😎😎😎😎

screenshot.webbuilds.nl/GJJAgF6rjBgwkeVj6kGr


  • Avatar
  • Avatar
  • P
Avatar

Dennis

Status changed to: In progress

Avatar

Dennis

So I would like to have some feedback on this feature request.

As we are certainly open to easily support this, I'd like to know how to solve this UI wise as a user?

A while ago, I already submitted a NodeJS webserver template to the marketplace: ploi.io/panel/marketplace/13-nodejs-webserver-template

Any feedback on how to solve this would be welcome (UI wise, the experience of the user).


  • Avatar
  • P
Avatar

theraloss

Hey Dennis,
when we create a site we normally have a "Laravel" sidebar link, I imagine that with Node.js we will have a dedicated section for that too.
It will contain some tweaks for PM2 process, some others will not be present because fully managed by Ploi, please see the attached screenshot.

What will be managed BY PLOI:

- Process name (we could let users customize it with a starting suggestion from the site name, but IDK)
- Log (log path)

Other options (except for --no-deamon, beacuse we will always want our process to be a deamon) will be available for the users like the screenshot.

I'm not sure if we should have the "watch" and "no-autorestart" flags, because they will impact the deploy too?

Talking about the deploy, maybe if there's only a package.json e no composer.json we could consider the project a "Node" project and suggest the deploy script like already happens for Laravel. I don't know what are the best practices for PM2 deploys: use `--watch` flag or `pm2 restart `? Maybe the second one?

PS: The link "PM2 docs" points to pm2.keymetrics.io/docs/usage/quick-start/#start-an-app
PPS: If these are too many fields, we could have just a simple "PM2 args" text input where we can pass our flags like --max-memory=200 etc., but we will need for sure a "Command to run" input.


  • Avatar
  • P
P

philipp

What do you think about Phusion Passenger instead of PM2?


  • Avatar
  • P
Avatar

theraloss

Never used Passenger tbh. I saw that there's a little more learning curve compared to PM2, but I think it could work anyway?


  • Avatar
  • P
Avatar

theraloss

Forgot to talk about the "Node" section! I'd love to see buttons for quick actions like Laravel (nice to have, not required to me, definitely a "second release"):

1. See all processes (pm2 list)
2. Start/Stop/Restart a process

"pm monit" is too complex to display it, Idk about "pm2 show " if it's complex to parse and display


  • Avatar
  • P
Avatar

Glenn Jacobs

This would be very handy, as we're doing more and more NuxtJS development and need a way to host.


  • Avatar
  • P
Avatar

BjarnBronsveld

Vouching for this too.

Using Phusion Passenger this is very easy to accomplish and also makes it easy to configure from the Ploi UI.

Phusion Passenger is a Nginx module, so it does not require any advanced setup like PM2 with processes.json configuration files.


  • Avatar
  • P
Avatar

Dennis

Status changed to: Planned

Avatar

Stefen Suhat

hi, is there any progress to support nodejs?


  • Avatar
  • P