This makes more sense
This commit is contained in:
parent
fdb9b0de95
commit
414b6232e4
|
@ -11,6 +11,8 @@ 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='7530'
|
||||||
|
|
||||||
|
service_pid=`lsof -i :"$cjdroute_listen_port" | tail -1 | cut -d ' ' -f 2`
|
||||||
|
|
||||||
cjdroute.create_tun() {
|
cjdroute.create_tun() {
|
||||||
ip tuntap add mode tun user "$service_username" group "$service_username" "$cjdroute_tun_interface"
|
ip tuntap add mode tun user "$service_username" group "$service_username" "$cjdroute_tun_interface"
|
||||||
ip a add "$cjdroute_ipv6_addr" dev "$cjdroute_tun_interface"
|
ip a add "$cjdroute_ipv6_addr" dev "$cjdroute_tun_interface"
|
||||||
|
@ -26,7 +28,6 @@ start() {
|
||||||
}
|
}
|
||||||
|
|
||||||
stop() {
|
stop() {
|
||||||
service_pid=`lsof -i :"$cjdroute_listen_port" | tail -1 | cut -d ' ' -f 2`
|
|
||||||
watchman.stop
|
watchman.stop
|
||||||
cjdroute.destroy_tun
|
cjdroute.destroy_tun
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user