search

Home  >  Q&A  >  body text

node.js - How to deploy nodejs application to server?

The thing is like this, I am doing front-end development. I recently learned nodejs and did some practice projects. I want to deploy them to the server, but I know little about Linux and server deployment. The general idea obtained through google is as follows: buy a vps to install a Linux system, install nodejs and mongodb, use Nginx for port mapping, and use pm2 for process monitoring and management. I found that these operations are all command line, and they feel very complicated, and there is a lot of unknown knowledge. I just want to deploy the project to the server. When I developed the program using PHP before, I just purchased a virtual host and uploaded the program via ftp. How do you deploy nodejs applications? Is there anything simple? method?

ringa_leeringa_lee2760 days ago1971

reply all(3)I'll reply

  • typecho

    typecho2017-06-29 10:10:54

    pm2
    http://pm2.keymetrics.io/docs...

    reply
    0
  • 学习ing

    学习ing2017-06-29 10:10:54

    You can use SSH to connect to the server and install node directly on the server (the specific installation commands vary by system), then upload your JS file through FTP, and finally enter node xxxx.js in SSH. (Of course, if there are dependent packages, npm install is required).

    reply
    0
  • 我想大声告诉你

    我想大声告诉你2017-06-29 10:10:54

    There is no easy way. Now that you know how to deploy it, just slowly install each module according to the command. It’s not scary if there are problems. How can you improve if you don’t do it? The more you work, the more progress you can make

    reply
    0
  • Cancelreply