summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xetc/rc.newwanip16
1 files changed, 12 insertions, 4 deletions
diff --git a/etc/rc.newwanip b/etc/rc.newwanip
index 999d0e8..480f5a2 100755
--- a/etc/rc.newwanip
+++ b/etc/rc.newwanip
@@ -97,6 +97,8 @@ system_resolvconf_generate(true);
/* write current WAN IP to file */
file_put_contents("{$g['vardb_path']}/{$interface}_ip", $curwanip);
+link_interface_to_vips($interface, "update");
+
unset($gre);
$gre = link_interface_to_gre($interface);
if (!empty($gre))
@@ -110,10 +112,16 @@ $grouptmp = link_interface_to_group($interface);
if (!empty($grouptmp))
array_walk($grouptmp, 'interface_group_add_member');
-unset($bridgetmp);
-$bridgetmp = link_interface_to_bridge($interface);
-if (!empty($bridgetmp))
- interface_bridge_add_member($bridgetmp, $interface_real);
+if ($linkupevent == false || substr($interface_real, 0, 4) == "ovpn") {
+ unset($bridgetmp);
+ $bridgetmp = link_interface_to_bridge($interface);
+ if (!empty($bridgetmp))
+ interface_bridge_add_member($bridgetmp, $interface_real);
+}
+
+/* make new hosts file */
+if ($interface == "lan")
+ system_hosts_generate();
/* check tunneled IPv6 interface tracking */
switch($config['interfaces'][$interface]['ipaddrv6']) {
OpenPOWER on IntegriCloud