treewide: use new extra_command function for init
This commit is contained in:
parent
63d1fa959c
commit
71f8f2a91d
@ -5,8 +5,7 @@ STOP=90
|
|||||||
|
|
||||||
BOOT_IMAGE=/boot/vmlinuz
|
BOOT_IMAGE=/boot/vmlinuz
|
||||||
|
|
||||||
EXTRA_COMMANDS="status"
|
extra_command "status" "Print crashkernel status"
|
||||||
EXTRA_HELP=" status Print crashkernel status"
|
|
||||||
|
|
||||||
verify_kdump() {
|
verify_kdump() {
|
||||||
local cfg="$1"
|
local cfg="$1"
|
||||||
|
|||||||
@ -4,11 +4,12 @@ USE_PROCD=1
|
|||||||
|
|
||||||
START=99
|
START=99
|
||||||
STOP=01
|
STOP=01
|
||||||
|
|
||||||
|
extra_command "test_crontab" "test_crontab"
|
||||||
|
|
||||||
CRON_FILE=/etc/crontabs/root
|
CRON_FILE=/etc/crontabs/root
|
||||||
CONFIGURATION=autoipsetadder
|
CONFIGURATION=autoipsetadder
|
||||||
EXTRA_COMMANDS="test_crontab"
|
|
||||||
EXTRA_HELP="
|
|
||||||
test_crontab"
|
|
||||||
set_dnsmasq_log()
|
set_dnsmasq_log()
|
||||||
{
|
{
|
||||||
sed -i '/log-facility/d' /etc/dnsmasq.conf
|
sed -i '/log-facility/d' /etc/dnsmasq.conf
|
||||||
|
|||||||
@ -11,9 +11,10 @@
|
|||||||
START=90
|
START=90
|
||||||
STOP=15
|
STOP=15
|
||||||
|
|
||||||
|
extra_command "rules"
|
||||||
|
|
||||||
SERVICE_DAEMONIZE=1
|
SERVICE_DAEMONIZE=1
|
||||||
NAME=vssr
|
NAME=vssr
|
||||||
EXTRA_COMMANDS=rules
|
|
||||||
|
|
||||||
#定义配置文件名称
|
#定义配置文件名称
|
||||||
CONFIG_FILE=/var/etc/${NAME}_t.json
|
CONFIG_FILE=/var/etc/${NAME}_t.json
|
||||||
|
|||||||
@ -2,6 +2,10 @@
|
|||||||
|
|
||||||
START=60
|
START=60
|
||||||
|
|
||||||
|
extra_command "makeconfig"
|
||||||
|
extra_command "makegfwlist"
|
||||||
|
extra_command "health"
|
||||||
|
|
||||||
CRON_FILE=/etc/crontabs/root
|
CRON_FILE=/etc/crontabs/root
|
||||||
PID_PATH=/var/run/dnsforwarder
|
PID_PATH=/var/run/dnsforwarder
|
||||||
PID_FILE=${PID_PATH}/dns.pid
|
PID_FILE=${PID_PATH}/dns.pid
|
||||||
@ -247,5 +251,3 @@ restart()
|
|||||||
/etc/init.d/dnsforwarder disable
|
/etc/init.d/dnsforwarder disable
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
EXTRA_COMMANDS="makeconfig makegfwlist health"
|
|
||||||
|
|||||||
@ -3,8 +3,10 @@
|
|||||||
START=96
|
START=96
|
||||||
STOP=10
|
STOP=10
|
||||||
|
|
||||||
|
extra_command "add_rule"
|
||||||
|
extra_command "del_rule"
|
||||||
|
extra_command "reload_rule"
|
||||||
|
|
||||||
EXTRA_COMMANDS="add_rule del_rule reload_rule"
|
|
||||||
PROG_PATH=/usr/share/adbyby
|
PROG_PATH=/usr/share/adbyby
|
||||||
DATA_PATH=$PROG_PATH/data
|
DATA_PATH=$PROG_PATH/data
|
||||||
WAN_FILE=/var/etc/dnsmasq-adbyby.d/03-adbyby-ipset.conf
|
WAN_FILE=/var/etc/dnsmasq-adbyby.d/03-adbyby-ipset.conf
|
||||||
|
|||||||
@ -11,9 +11,10 @@
|
|||||||
START=90
|
START=90
|
||||||
STOP=15
|
STOP=15
|
||||||
|
|
||||||
|
extra_command "rules"
|
||||||
|
|
||||||
SERVICE_DAEMONIZE=1
|
SERVICE_DAEMONIZE=1
|
||||||
NAME=brook
|
NAME=brook
|
||||||
EXTRA_COMMANDS=rules
|
|
||||||
FWI=$(uci get firewall.brook.path 2>/dev/null)
|
FWI=$(uci get firewall.brook.path 2>/dev/null)
|
||||||
|
|
||||||
uci_get_by_name() {
|
uci_get_by_name() {
|
||||||
|
|||||||
@ -7,11 +7,9 @@ START=95
|
|||||||
USE_PROCD=1
|
USE_PROCD=1
|
||||||
#PROCD_DEBUG=1
|
#PROCD_DEBUG=1
|
||||||
|
|
||||||
EXTRA_COMMANDS="status flush libver"
|
extra_command "flush" "Flush DNS cache stored in Pcap_DNSProxy and DNSMasq"
|
||||||
EXTRA_HELP=\
|
extra_command "libver" "Print library version Pcap_DNSProxy linked to"
|
||||||
" flush Flush DNS cache stored in Pcap_DNSProxy and DNSMasq
|
extra_command "status" "Show the running status of Pcap_DNSProxy"
|
||||||
libver Print library version Pcap_DNSProxy linked to
|
|
||||||
status Show the running status of Pcap_DNSProxy"
|
|
||||||
|
|
||||||
PROG=/usr/sbin/Pcap_DNSProxy
|
PROG=/usr/sbin/Pcap_DNSProxy
|
||||||
CONFDIR=/etc/pcap-dnsproxy
|
CONFDIR=/etc/pcap-dnsproxy
|
||||||
|
|||||||
@ -7,10 +7,7 @@ USE_PROCD=1
|
|||||||
SCUTCLIENT_PATH=/usr/bin/scutclient
|
SCUTCLIENT_PATH=/usr/bin/scutclient
|
||||||
SCUTCLIENT_CONFIG=scutclient
|
SCUTCLIENT_CONFIG=scutclient
|
||||||
|
|
||||||
EXTRA_COMMANDS="logoff"
|
extra_command "logoff" "Log off manually"
|
||||||
EXTRA_HELP=<<EOF
|
|
||||||
logoff Log off manually
|
|
||||||
EOF
|
|
||||||
|
|
||||||
scutclient_validate_drcom() {
|
scutclient_validate_drcom() {
|
||||||
uci_validate_section scutclient drcom "${1}" \
|
uci_validate_section scutclient drcom "${1}" \
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user