Try harder to determine interface device names
And also allow the wan-failover config to override it in case it's not in the network config, which it seems like it isn't anymore.
This commit is contained in:
@ -50,9 +50,9 @@ cfg_init() {
|
||||
check_interval=$(ourcfg globals.check_interval || echo $default_check_interval)
|
||||
|
||||
primary_iface=$(ourcfg globals.primary || echo '')
|
||||
primary_ifname=$(cfg network.$primary_iface.ifname || echo '')
|
||||
primary_ifname=$(ourcfg wan.ifname || cfg network.$primary_iface.ifname || cfg network.$primary_iface.device || echo '')
|
||||
fallback_iface=$(ourcfg globals.fallback || echo '')
|
||||
fallback_ifname=$(cfg network.$fallback_iface.ifname || echo '')
|
||||
fallback_ifname=$(ourcfg wwan.ifname || cfg network.$fallback_iface.ifname || cfg network.$fallback_iface.device || echo '')
|
||||
|
||||
primary_health_ips=$(ourcfg $primary_iface.ip || echo $default_health_ips)
|
||||
primary_ping_count=$(ourcfg $primary_iface.count || echo $default_ping_count)
|
||||
|
Reference in New Issue
Block a user