centos7 安装 supervisor
一、安装 supervisor
yum install python-setuptools
easy_install supervisor
如果easy_install不好使就从官方下载:
wget https://pypi.python.org/packages/80/37/964c0d53cbd328796b1aeb7abea4c0f7b0e8c7197ea9b0b9967b7d004def/supervisor-3.3.1.tar.gz
然后通过python安装:
t
ar zxf supervisor-3.3.1.tar.gz
cd supervisor
python setup.py install
二、配置 supervisor
1、创建文件和配置文件
mkdir /etc/supervisor
echo_supervisord_conf > /etc/supervisor/supervisord.conf
2、修改/etc/supervisor/supervisord.conf文件内容
在文件结尾[include]节点处
把;files = relative/directory/*.ini
改为files = conf.d/*.conf
3、执行supervisorctl reload命令使配置文件生效。
4、在/etc/supervisor/下创建conf.d文件夹,及ProjectName.conf(以项目名称命名的)
5、打开ProjectName.conf文件,添加内容如下:
[program: ProjectName]
command=dotnet ProjectName.dll ; 运行程序的命令
directory=/root/Publishing/PublishOutput/ ; 命令执行的目录
autorestart=true ; 程序意外退出是否自动重启
autostart=true ; 是否自动启动
stderr_logfile=/var/log/ProjectName.err.log ; 错误日志文件
stdout_logfile=/var/log/ProjectName.out.log ; 输出日志文件
environment=ASPNETCORE_ENVIRONMENT=Production ; 进程环境变量
user=root ; 进程执行的用户身份
stopsignal=INT
startsecs= ; 自动重启间隔
6、运行supervisord,查看是否生效,执行以下命令:
supervisord -c /etc/supervisor/ supervisord.conf
ps -ef | grep ProjectName
返回
root 27007 27006 1 13:21 ? 00:00:02 dotnet ProjectName.dll
root 27026 26810 0 13:23 pts/0 00:00:00 grep --color=auto ProjectName 参考:https://www.cnblogs.com/Hai--D/p/5820718.html
centos7 安装 supervisor的更多相关文章
- CentOS7 安装supervisor守护进程管理器
supervisor没有发布在标准的CentOS源在,需要安装epel源.这种方式安装的可能不是最新版本,但比较方便,安装完成之后,配置文件会自动帮你生成. 默认配置文件:/etc/superviso ...
- centos7安装supervisor
安装supervisor cd /root/tools/ wget http://pnxcvm0bq.bkt.clouddn.com/get-pip.py python get-pip.py pip ...
- CentOS7 下 安装 supervisor以及使用
CentOS7 下 安装 supervisor 以及使用 手动安装 [注] linux环境必须安装 python 1.获取supervisor包:[https://pypi.python.org/py ...
- CentOS7下Supervisor安装与配置
Supervisor(http://supervisord.org/)是用Python开发的一个client/server服务,是Linux/Unix系统下的一个进程管理工具,不支持Windows系统 ...
- [原创]Centos7 安装配置ASP.NET Core+Nginx+Supervisor
序言 此教程安装的都是最新版本的. 一键安装 有了这个神器,下面的教程就不用做了!只需运行几行代码,直接打开浏览器就可以访问! cd /home/ wget https://files.cnblogs ...
- Centos7 使用 Supervisor 守护进程 Celery
一.Supervisor 安装(centos7 还有另一个进程守护命令 Systemd ) Centos 7 安装 Supervisord 二.Supervisor 守护进程 Centos7 使用 S ...
- CentOS7安装Supervisor3.1.4
supervisord 负责管理进程的server端,配置文件是/etc/supervisor/supervisord.conf supervisorctl client端的命令行工具,管理子进程,配 ...
- CentOS7 安装配置笔记
CentOS7 安装配置笔记 1.通过镜像安装 CentOS7 ==============================* 使用 UltraISO 9.7 或者 rufus-3.5p 制作ISO的 ...
- 部署 Nginx +uwsgi+centos7+django+supervisor 项目
部署CRM项目 前言 使用软件 nginx 使用nginx是为了它的反向代理功能,项目会通过Django+uWSGI+Nginx进行服务器线上部署. uWSGI python web服务器开发使用WS ...
随机推荐
- js计时器方法的使用
js中计时器重要使用window.setInterval()方法和window.setTimeout()方法, 其中setInterval()方法的作用是每隔一段时间执行一次方法,而window.se ...
- 用Python来进行词频统计
# 把语料中的单词全部抽取出来, 转成小写, 并且去除单词中间的特殊符号 def words(text): return re.findall('[a-z]+', text.lower()) def ...
- idea 永久注册
1.在百度输入http://idea.lanyus.com/ 2.点击这个网址http://idea.lanyus.com/jar/JetbrainsCrack-3.1-release-enc.ja ...
- soj2013.Pay Back
2013. Pay Back Constraints Time Limit: 1 secs, Memory Limit: 256 MB Description "Never a borrow ...
- 谈谈Flash图表中数据的采集
一般来说flash中的数据是不能被现有技术很容易采集到的,但是也不能谈flash色变,要具体问题具体分析,有些flash是可以通过一些分析发现背后的数据.然后采集就变得很容易了. 具体案例:搜房房价走 ...
- C# Func的同步、异步调用
using System; namespace ActionDemo { class Program { static void Main(string[] args) { Console.Write ...
- HTML5之2D物理引擎 Box2D for javascript Games 系列 翻外篇--如何结合createJS应用box2d.js
太久没有更新了,新年回来工作,突然有收到网友的邮件提问,居然还有人在关注,惭愧,找了下电脑上还有一点儿存着,顺便先发这一个番外篇吧,好歹可以看到真实的效果,等我考完英语,一定会更新下一章," ...
- [转]CNN目标检测(一):Faster RCNN详解
https://blog.csdn.net/a8039974/article/details/77592389 Faster RCNN github : https://github.com/rbgi ...
- javaScript书写规范
命名规范. 常量名 全部大写并单词间用下划线分隔 如:CSS_BTN_CLOSE.TXT_LOADING对象的属性或方法名 小驼峰式(little camel-case) 如: ...
- 2016.5.19——Excel Sheet Column Title
Excel Sheet Column Title 本题收获: 1.由int型转换为整型(string),如何转化, res = 'A'+(n-1)%26和之前由A-z转化为十进制相反,res = s[ ...