added swap
This commit is contained in:
Symlink
+1
@@ -0,0 +1 @@
|
||||
../../usr/lib/init/services/swap.service
|
||||
@@ -0,0 +1,33 @@
|
||||
#!/bin/sh
|
||||
|
||||
#--- import colors and init-funcs ---
|
||||
. /usr/lib/init/colors.sh
|
||||
. /usr/lib/init/init-funcs.sh
|
||||
#------------------------------------
|
||||
|
||||
SWAPON_OPTS="-a"
|
||||
SWAPOFF_OPTS="-a"
|
||||
|
||||
start() {
|
||||
notify "Starting swap"
|
||||
/usr/bin/swapon $SWAPON_OPTS
|
||||
check $? "start swap"
|
||||
return $?
|
||||
}
|
||||
|
||||
stop() {
|
||||
notify "Stopping swap"
|
||||
/usr/bin/swapoff $SWAPOFF_OPTS
|
||||
check $? "stop swap"
|
||||
return $?
|
||||
}
|
||||
|
||||
case "$1" in
|
||||
start|stop|restart|reload|help)
|
||||
"$1"
|
||||
;;
|
||||
*)
|
||||
help
|
||||
return 1
|
||||
esac
|
||||
return $?
|
||||
+15
-14
@@ -3,17 +3,18 @@
|
||||
03syslogd
|
||||
04swap
|
||||
05networking
|
||||
06sysctl
|
||||
07crond
|
||||
08dnsmasq
|
||||
09dnsd
|
||||
10telnetd
|
||||
11sshd
|
||||
12iptables
|
||||
13ftpd
|
||||
14hostapd
|
||||
15httpd
|
||||
16nginx
|
||||
17openrouterinit
|
||||
18dropbear
|
||||
19gitea
|
||||
06netplugd
|
||||
07sysctl
|
||||
08crond
|
||||
09dnsmasq
|
||||
10dnsd
|
||||
11telnetd
|
||||
12sshd
|
||||
13iptables
|
||||
14ftpd
|
||||
15hostapd
|
||||
16httpd
|
||||
17nginx
|
||||
18openrouterinit
|
||||
19dropbear
|
||||
20gitea
|
||||
|
||||
Reference in New Issue
Block a user