mirror of
https://github.com/YunoHost-Apps/hotspot_ynh.git
synced 2024-09-03 19:25:53 +02:00
Fix issue of gateway interface detection in the case of VPN usage
This commit is contained in:
parent
ecf91a8ecd
commit
e725d58f7b
1 changed files with 1 additions and 2 deletions
|
@ -236,8 +236,7 @@ if [ "$1" != restart ]; then
|
|||
ip4_nat_prefix=$(ynh_app_setting_get --app=$app --key=ip4_nat_prefix)
|
||||
|
||||
old_gateway_interface=$(ynh_app_setting_get --app=$app --key=gateway_interface)
|
||||
new_gateway_interface=$(ip route get 1.2.3.4 | awk '{ print $5; }')
|
||||
|
||||
new_gateway_interface=$(ip route get 1.2.3.4 | awk '$2 ~ /^dev$/ { print $3; } $4 ~ /^dev$/ { print $5; }')
|
||||
echo "OK"
|
||||
fi
|
||||
|
||||
|
|
Loading…
Reference in a new issue