标签:style blog http color ar for 文件 art div
supervisor是把普通app变成deamon的工具,虽然没有erlang的supervise粒度那么细,但是已经非常方便了
安装
sudo apt-get install supervisor
修改配置文件
sudo gvim /etc/supervisor/supervisord.conf
添加下面的以支持web管理
[inet_http_server] port=9001 username=admin password=admin
新建单独的配置
sudo gvim /etc/supervisor/conf.d/ss.conf
[program:ss] command=/home/mmc/tools/ss/cli/ss -c="/home/mmc/tools/ss/cli/config.json" autorstart=true stdout_logfile=/home/mmc/tools/ss/cli/supervisor.log
supervisor的命令
sudo invoke-rc.d supervisor start
sudo supervisorctl status ss
如果启动的时候报错
* Starting Supervisor daemon manager... Error: Another program is already listening on a port that one of our HTTP servers is configured to use. Shut this program down first before starting supervisord. For help, use /usr/bin/supervisord -h ...fail!
解决办法
sudo find / -name supervisor.sock sudo unlink /***/supervisor.sock
标签:style blog http color ar for 文件 art div
原文地址:http://www.cnblogs.com/ziyouchutuwenwu/p/3961790.html