mirror of
https://github.com/Ysurac/openmptcprouter-vps.git
synced 2025-03-09 15:50:00 +00:00
Set VPN IP only when possible
This commit is contained in:
parent
adabff20cb
commit
42c7489c23
3 changed files with 18 additions and 4 deletions
10
omr-service
10
omr-service
|
@ -18,6 +18,15 @@ _glorytun_udp() {
|
|||
logger -t "OMR-Service" "Restart Glorytun-UDP"
|
||||
systemctl -q restart glorytun-udp@*
|
||||
}
|
||||
for intf in /etc/glorytun-udp/*; do
|
||||
/etc/glorytun-udp/post.sh /etc/glorytun-udp/${intf}
|
||||
done
|
||||
}
|
||||
|
||||
_glorytun_tcp() {
|
||||
for intf in /etc/glorytun-tcp/*; do
|
||||
/etc/glorytun-tcp/post.sh /etc/glorytun-tcp/${intf}
|
||||
done
|
||||
}
|
||||
|
||||
_omr_api() {
|
||||
|
@ -29,6 +38,7 @@ _omr_api() {
|
|||
|
||||
while true; do
|
||||
_glorytun_udp
|
||||
_glorytun_tcp
|
||||
_multipath
|
||||
_omr_api
|
||||
sleep 10
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue