1
0
Fork 0
mirror of https://github.com/ossrs/srs.git synced 2025-03-09 15:49:59 +00:00

Package rpm support for CentOS/RHEL (#2701)

* rpm support

提供全套rpm打包方案,降低软件使用的入门难度:
1、FHS路径标准化
2、全新的init/systemd启动脚本,同时支持el6和el7
3、普通用户身份运行
4、开箱即用的默认配置文件
5、自动日志轮转

* Create srs.spec
This commit is contained in:
Purple Grape 2021-11-03 07:36:54 +08:00 committed by GitHub
parent 6e2500a569
commit 75909c82d0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 255 additions and 0 deletions

View file

@ -0,0 +1,23 @@
[Unit]
Description=srs - a simple, high efficiency and realtime video server
Documentation=https://github.com/ossrs/srs/wiki
After=network-online.target remote-fs.target nss-lookup.target
Wants=network-online.target
[Service]
Type=simple
User=nobody
Group=nobody
WorkingDirectory=/var/lib/srs
EnvironmentFile=-/etc/sysconfig/srs
PIDFile=/var/lib/srs/srs.pid
ExecStartPre=/usr/bin/srs -c /etc/srs/srs.conf -t
ExecStart=/usr/bin/srs -c /etc/srs/srs.conf
ExecReload=/bin/kill -s HUP $MAINPID
ExecStop=/bin/kill -s TERM $MAINPID
Restart=on-failure
PrivateTmp=true
[Install]
WantedBy=multi-user.target