Toggle navigation
Toggle navigation
此项目
正在载入...
Sign in
胡斌
/
srs
转到一个项目
Toggle navigation
项目
群组
代码片段
帮助
Toggle navigation pinning
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Authored by
winlin
2014-03-30 11:14:57 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
37fe08a302a3bb353c087370bf4084bfe280c08e
37fe08a3
1 parent
2dcde77b
support debian and raspbian
隐藏空白字符变更
内嵌
并排对比
正在显示
1 个修改的文件
包含
12 行增加
和
0 行删除
trunk/scripts/install.sh
trunk/scripts/install.sh
查看文件 @
37fe08a
...
...
@@ -81,6 +81,8 @@ ok_msg "install init.d scripts success"
# install system service
lsb_release --id|grep
"CentOS"
>/dev/null 2>&1;
os_id_centos
=
$?
lsb_release --id|grep
"Ubuntu"
>/dev/null 2>&1;
os_id_ubuntu
=
$?
lsb_release --id|grep
"Debian"
>/dev/null 2>&1;
os_id_debian
=
$?
lsb_release --id|grep
"Raspbian"
>/dev/null 2>&1;
os_id_rasabian
=
$?
if
[[
0 -eq
$os_id_centos
]]
;
then
ok_msg
"install system service for CentOS"
/sbin/chkconfig --add srs
&&
/sbin/chkconfig srs on
...
...
@@ -91,6 +93,16 @@ elif [[ 0 -eq $os_id_ubuntu ]]; then
update-rc.d srs defaults
ret
=
$?
;
if
[[
0 -ne
${
ret
}
]]
;
then
failed_msg
"install system service failed"
;
exit
$ret
;
fi
ok_msg
"install system service success"
elif
[[
0 -eq
$os_id_debian
]]
;
then
ok_msg
"install system service for Debian"
update-rc.d srs defaults
ret
=
$?
;
if
[[
0 -ne
${
ret
}
]]
;
then
failed_msg
"install system service failed"
;
exit
$ret
;
fi
ok_msg
"install system service success"
elif
[[
0 -eq
$os_id_rasabian
]]
;
then
ok_msg
"install system service for RaspberryPi"
update-rc.d srs defaults
ret
=
$?
;
if
[[
0 -ne
${
ret
}
]]
;
then
failed_msg
"install system service failed"
;
exit
$ret
;
fi
ok_msg
"install system service success"
else
warn_msg
"ignore and donot install system service for
`
lsb_release --id|awk
'{print $3}'
`
."
fi
...
...
请
注册
或
登录
后发表评论