mirror of
https://github.com/3proxy/3proxy.git
synced 2026-11-22 23:59:41 +08:00
Unify installation environment
This commit is contained in:
1 parent
01dad546b7
commit
f0a672b16a
19 files changed
+185
-220
No files matched your search
@@ -14,7 +14,7 @@
|
||||
# description: 3proxy tiny proxy server
|
||||
|
||||
DAEMON=@CMAKE_INSTALL_FULL_BINDIR@/3proxy
|
||||
CONFIGFILE=/etc/3proxy/3proxy.cfg
|
||||
CONFIGFILE=@CMAKE_INSTALL_FULL_SYSCONFDIR@/3proxy/3proxy.cfg
|
||||
PIDFILE=/var/run/3proxy/3proxy.pid
|
||||
USER=proxy
|
||||
GROUP=proxy
|
||||
|
||||
@@ -1,56 +0,0 @@
|
||||
#!/bin/sh
|
||||
### BEGIN INIT INFO
|
||||
# Provides: 3proxy
|
||||
# Required-Start:
|
||||
# Required-Stop:
|
||||
# Should-Start:
|
||||
# Should-Stop:
|
||||
# Default-Start: 2 3 4 5
|
||||
# Default-Stop: 0 1 6
|
||||
# Short-Description: Start/stop 3proxy
|
||||
# Description: Start/stop 3proxy, tiny proxy server
|
||||
### END INIT INFO
|
||||
# chkconfig: 2345 20 80
|
||||
# description: 3proxy tiny proxy server
|
||||
|
||||
case "$1" in
|
||||
start)
|
||||
echo Starting 3Proxy
|
||||
|
||||
/bin/mkdir -p /var/run/3proxy
|
||||
/bin/3proxy /etc/3proxy/3proxy.cfg &
|
||||
|
||||
RETVAL=$?
|
||||
echo
|
||||
[ $RETVAL ]
|
||||
;;
|
||||
|
||||
stop)
|
||||
echo Stopping 3Proxy
|
||||
if [ -f /var/run/3proxy/3proxy.pid ]; then
|
||||
/bin/kill `cat /var/run/3proxy/3proxy.pid`
|
||||
else
|
||||
/usr/bin/killall 3proxy
|
||||
fi
|
||||
|
||||
RETVAL=$?
|
||||
echo
|
||||
[ $RETVAL ]
|
||||
;;
|
||||
|
||||
restart|reload)
|
||||
echo Reloading 3Proxy
|
||||
if [ -f /var/run/3proxy/3proxy.pid ]; then
|
||||
/bin/kill -s USR1 `cat /var/run/3proxy/3proxy.pid`
|
||||
else
|
||||
/usr/bin/killall -s USR1 3proxy
|
||||
fi
|
||||
;;
|
||||
|
||||
|
||||
*)
|
||||
echo Usage: $0 "{start|stop|restart}"
|
||||
exit 1
|
||||
esac
|
||||
exit 0
|
||||
|
||||
Reference in new issue
Block a user