forked from Spark/ssm-services
cjdroute script update
This commit is contained in:
parent
3cf24fa2dd
commit
c710dcd56d
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
unset reload
|
unset reload
|
||||||
|
|
||||||
service_command='/usr/local/sbin/cjdroute'
|
service_command='/usr/bin/cjdroute'
|
||||||
|
|
||||||
cjdroute_config='/etc/cjdroute.conf'
|
cjdroute_config='/etc/cjdroute.conf'
|
||||||
cjdroute_tun_interface='cjdns0'
|
cjdroute_tun_interface='cjdns0'
|
||||||
|
@ -21,5 +21,11 @@ cjdroute.check_tun_module() {
|
||||||
|
|
||||||
start() {
|
start() {
|
||||||
cjdroute.check_tun_module || { return 1; }
|
cjdroute.check_tun_module || { return 1; }
|
||||||
|
|
||||||
|
[[ -e "$cjdroute_config" ]] || {
|
||||||
|
watchman.err "$cjdroute_config does not exist, please create it by running cjdroute --genconf >> /etc/cjdroute.conf"
|
||||||
|
return 1
|
||||||
|
}
|
||||||
|
|
||||||
"$service_command" < "$cjdroute_config"
|
"$service_command" < "$cjdroute_config"
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user