Skip to content

Commit

Permalink
remove -quiet in openwrt init script, fixed #4
Browse files Browse the repository at this point in the history
  • Loading branch information
IrineSistiana committed Dec 2, 2020
1 parent bc20bad commit 6d741fe
Showing 1 changed file with 15 additions and 15 deletions.
30 changes: 15 additions & 15 deletions scripts/openwrt/mosdns-init-openwrt
Original file line number Diff line number Diff line change
Expand Up @@ -5,26 +5,26 @@ START=99
USE_PROCD=1

##### ONLY CHANGE THIS BLOCK ######
PROG=/usr/bin/mosdns # where is mosdns
RES_DIR=/etc/mosdns/ # resource dir / working dir / the dir where you store ip/domain lists
CONF=./config.yaml # where is the config file, it can be a relative path to $RES_DIR
PROG=/usr/bin/mosdns # where is mosdns
RES_DIR=/etc/mosdns/ # resource dir / working dir / the dir where you store ip/domain lists
CONF=./config.yaml # where is the config file, it can be a relative path to $RES_DIR
##### ONLY CHANGE THIS BLOCK ######

start_service() {
procd_open_instance
procd_set_param command $PROG -dir $RES_DIR -c $CONF -quiet
procd_open_instance
procd_set_param command $PROG -dir $RES_DIR -c $CONF

procd_set_param user root
procd_set_param stdout 1
procd_set_param stderr 1
procd_set_param respawn ${respawn_threshold:-3600} ${respawn_timeout:-5} ${respawn_retry:-5}
procd_close_instance
echo "mosdns is started!"
procd_set_param user root
procd_set_param stdout 1
procd_set_param stderr 1
procd_set_param respawn "${respawn_threshold:-3600}" "${respawn_timeout:-5}" "${respawn_retry:-5}"
procd_close_instance
echo "mosdns is started!"
}

reload_service() {
stop
sleep 2s
echo "mosdns is restarted!"
start
stop
sleep 2s
echo "mosdns is restarted!"
start
}

0 comments on commit 6d741fe

Please # to comment.