Running NodeJs http-server forever with PM2

后端 未结 4 1293
灰色年华
灰色年华 2021-02-04 04:18

My question is about running HTTP-server in combination with PM2.

The problem I face is that:

  1. HTTP-server requires as input a folder which is the root of the
4条回答
  •  忘了有多久
    2021-02-04 04:24

    if we have a build generated by grunt,then go to its path and hit:

    ~/app/build/prod$ sudo pm2 start /usr/local/bin/http-server -p 8080
    

    Now check app status at localhost:8080

提交回复
热议问题