Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to "npm start" with supervisord?

I have a simple question. How does a supervisord config look like to start an express app?

[supervisord]
nodaemon=true

[program:sshd]
command=/usr/sbin/sshd -D

[programm:api]
directory=/var/www/my_api
command=npm start

I also tried with:

[programm:api]
command=node /var/www/my_api/app.js

However it does not start and no errors are logged. Any ideas?

like image 786
UpCat Avatar asked Jan 23 '15 11:01

UpCat


1 Answers

A typo was causing the problem

[programm:api]

is wrong. Right:

[program:api]
like image 83
UpCat Avatar answered Sep 30 '22 13:09

UpCat