Run success or not
This commit is contained in:
parent
b5110373c8
commit
da9e1ec2d3
|
|
@ -129,8 +129,10 @@ function install(){
|
||||||
if [ $? -ne 0 ]; then
|
if [ $? -ne 0 ]; then
|
||||||
echo "nohup /usr/local/bin/ss-server -c /etc/shadowsocks/config.json > /dev/null 2>&1 &" >> /etc/rc.local
|
echo "nohup /usr/local/bin/ss-server -c /etc/shadowsocks/config.json > /dev/null 2>&1 &" >> /etc/rc.local
|
||||||
fi
|
fi
|
||||||
# Start shadowsocks
|
# Run shadowsocks in the background
|
||||||
nohup /usr/local/bin/ss-server -c /etc/shadowsocks/config.json > /dev/null 2>&1 &
|
nohup /usr/local/bin/ss-server -c /etc/shadowsocks/config.json > /dev/null 2>&1 &
|
||||||
|
# Run success or not
|
||||||
|
ps -ef | grep -v grep | grep -v ps | grep -i '/usr/local/bin/ss-server' > /dev/null 2>&1
|
||||||
if [ $? -eq 0 ]; then
|
if [ $? -eq 0 ]; then
|
||||||
echo "Shadowsocks-libev start success!"
|
echo "Shadowsocks-libev start success!"
|
||||||
else
|
else
|
||||||
|
|
|
||||||
|
|
@ -151,6 +151,8 @@ function install(){
|
||||||
# Run it in the background
|
# Run it in the background
|
||||||
if [ -s /usr/local/bin/ssserver ]; then
|
if [ -s /usr/local/bin/ssserver ]; then
|
||||||
nohup ssserver -c /etc/config.json > /dev/null 2>&1 &
|
nohup ssserver -c /etc/config.json > /dev/null 2>&1 &
|
||||||
|
# Run success or not
|
||||||
|
ps -ef | grep -v grep | grep -v ps | grep -i 'node /usr/local/bin/ssserver' > /dev/null 2>&1
|
||||||
if [ $? -eq 0 ]; then
|
if [ $? -eq 0 ]; then
|
||||||
echo "Shadowsocks-nodejs start success!"
|
echo "Shadowsocks-nodejs start success!"
|
||||||
else
|
else
|
||||||
|
|
|
||||||
|
|
@ -135,7 +135,10 @@ function install(){
|
||||||
pip install gevent
|
pip install gevent
|
||||||
pip install shadowsocks
|
pip install shadowsocks
|
||||||
if [ -f /usr/bin/ssserver ]; then
|
if [ -f /usr/bin/ssserver ]; then
|
||||||
|
# Run shadowsocks in the background
|
||||||
nohup ssserver -c /etc/config.json > /dev/null 2>&1 &
|
nohup ssserver -c /etc/config.json > /dev/null 2>&1 &
|
||||||
|
# Run success or not
|
||||||
|
ps -ef | grep -v grep | grep -v ps | grep -i '/usr/bin/python /usr/bin/ssserver' > /dev/null 2>&1
|
||||||
if [ $? -eq 0 ]; then
|
if [ $? -eq 0 ]; then
|
||||||
echo "Shadowsocks start success!"
|
echo "Shadowsocks start success!"
|
||||||
else
|
else
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user