update scripts
This commit is contained in:
1 parent
95e2551110
commit
4a8ea1b190
17 files changed
+381
-126
No files matched your search
Executable
+32
@@ -0,0 +1,32 @@
|
||||
#!/bin/sh
|
||||
|
||||
#--- import colors and init-funcs ---
|
||||
. /usr/lib/init/colors.sh
|
||||
. /usr/lib/init/init-funcs.sh
|
||||
#------------------------------------
|
||||
|
||||
start() {
|
||||
notify "Starting sshd"
|
||||
/usr/bin/sshd -D &
|
||||
check $? "start sshd"
|
||||
echo $(pgrep sshd) > /var/run/sshd.pid
|
||||
return $?
|
||||
}
|
||||
|
||||
stop() {
|
||||
notify "Stopping sshd"
|
||||
kill $(cat /var/run/sshd.pid)
|
||||
check $? "stop sshd"
|
||||
rm /var/run/sshd.pid &> /dev/null
|
||||
return $?
|
||||
}
|
||||
|
||||
case "$1" in
|
||||
start|stop|restart|reload|help)
|
||||
"$1"
|
||||
;;
|
||||
*)
|
||||
help
|
||||
;;
|
||||
esac
|
||||
return $?
|
||||
Reference in new issue
Block a user