a bit saner defaults
This commit is contained in:
parent
aa2293ae2f
commit
4194c2ec77
|
@ -3,13 +3,12 @@
|
||||||
unset reload
|
unset reload
|
||||||
|
|
||||||
service_username='cjdns'
|
service_username='cjdns'
|
||||||
service_command='/home/cjdns/cjdns/cjdroute'
|
service_command='/usr/local/sbin/cjdroute'
|
||||||
service_args='< /home/cjdns/cjdns/cjdroute.conf'
|
service_args='< /etc/cjdns/cjdroute.conf'
|
||||||
service_logfile='/home/cjdns/cjdns/cjdroute.log'
|
|
||||||
|
|
||||||
cjdroute_tun_interface='cjd0'
|
cjdroute_tun_interface='cjd0'
|
||||||
cjdroute_ipv6_addr='fca7:8aef:6571:63c5:b23c:2fbc:8dea:e207/8'
|
cjdroute_ipv6_addr='fca7:8aef:6571:63c5:b23c:2fbc:8dea:e207/8'
|
||||||
cjdroute_listen_port='7530'
|
cjdroute_listen_port='11270'
|
||||||
|
|
||||||
service_pid=`lsof -i :"$cjdroute_listen_port" | tail -1 | cut -d ' ' -f 2`
|
service_pid=`lsof -i :"$cjdroute_listen_port" | tail -1 | cut -d ' ' -f 2`
|
||||||
|
|
||||||
|
@ -24,10 +23,15 @@ cjdroute.destroy_tun() {
|
||||||
}
|
}
|
||||||
|
|
||||||
start() {
|
start() {
|
||||||
cjdroute.create_tun && watchman.start
|
[[ "$service_username" ]] && {
|
||||||
|
cjdroute.create_tun || { return 1; }
|
||||||
|
}
|
||||||
|
|
||||||
|
watchman.start
|
||||||
}
|
}
|
||||||
|
|
||||||
stop() {
|
stop() {
|
||||||
watchman.stop
|
watchman.stop
|
||||||
cjdroute.destroy_tun
|
|
||||||
|
[[ "$service_username" ]] && { cjdroute.destroy_tun; }
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user