mirror of
https://github.com/lucaspalomodevelop/core.git
synced 2026-03-13 08:09:41 +00:00
interfaces: clean up reload structure for single interfaces
This commit is contained in:
parent
0abc31dcad
commit
f3caafbe04
2
plist
2
plist
@ -84,6 +84,7 @@
|
||||
/usr/local/etc/rc.carpbackup
|
||||
/usr/local/etc/rc.carpmaster
|
||||
/usr/local/etc/rc.configure_firmware
|
||||
/usr/local/etc/rc.configure_interface
|
||||
/usr/local/etc/rc.configure_plugins
|
||||
/usr/local/etc/rc.d/captiveportal
|
||||
/usr/local/etc/rc.d/configd
|
||||
@ -96,7 +97,6 @@
|
||||
/usr/local/etc/rc.firmware.subr
|
||||
/usr/local/etc/rc.freebsd
|
||||
/usr/local/etc/rc.halt
|
||||
/usr/local/etc/rc.interfaces_wan_configure
|
||||
/usr/local/etc/rc.ipfw
|
||||
/usr/local/etc/rc.ipfw.flush_all
|
||||
/usr/local/etc/rc.ipfw.postload
|
||||
|
||||
@ -1136,8 +1136,6 @@ function interface_bring_down($interface = "wan", $ifacecfg = false)
|
||||
kill_hostapd($realif);
|
||||
mwexec(kill_wpasupplicant($realif));
|
||||
}
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
function interfaces_ptpid_used($ptpid)
|
||||
@ -2518,7 +2516,13 @@ function interface_configure($interface = 'wan', $reload = false, $linkupevent =
|
||||
if (!empty($grouptmp)) {
|
||||
array_walk($grouptmp, 'interface_group_add_member');
|
||||
}
|
||||
}
|
||||
|
||||
if ($verbose) {
|
||||
echo "done.\n";
|
||||
}
|
||||
|
||||
if (!file_exists("/var/run/booting")) {
|
||||
if ($reload) {
|
||||
system_routing_configure($verbose, $interface);
|
||||
ipsec_configure_do($verbose, $interface);
|
||||
@ -2528,10 +2532,6 @@ function interface_configure($interface = 'wan', $reload = false, $linkupevent =
|
||||
}
|
||||
|
||||
interfaces_staticarp_configure($interface);
|
||||
|
||||
if ($verbose) {
|
||||
echo "done.\n";
|
||||
}
|
||||
}
|
||||
|
||||
function interface_track6_configure($interface = 'lan', $lancfg, $linkupevent = false)
|
||||
|
||||
@ -35,11 +35,6 @@ require_once("system.inc");
|
||||
require_once("interfaces.inc");
|
||||
require_once("services.inc");
|
||||
|
||||
if (!empty($argv[1])) {
|
||||
$argument = str_replace("\n", "", $argv[1]);
|
||||
if (!empty($config['interfaces'][$argument])) {
|
||||
interface_configure($argument);
|
||||
}
|
||||
} else {
|
||||
interface_configure("wan");
|
||||
}
|
||||
$argument = isset($argv[1]) ? trim($argv[1]) : 'wan';
|
||||
|
||||
interface_configure($argument, true, false, true);
|
||||
@ -1,5 +1,5 @@
|
||||
[reconfigure]
|
||||
command:/usr/local/etc/rc.interfaces_wan_configure
|
||||
command:/usr/local/etc/rc.configure_interface
|
||||
parameters:%s
|
||||
type:script
|
||||
message:Configuring interface %s
|
||||
|
||||
@ -39,7 +39,7 @@ if ($_SERVER['REQUEST_METHOD'] === 'POST') {
|
||||
if (!empty($_POST['status']) && $_POST['status'] == 'up') {
|
||||
interface_bring_down($interface);
|
||||
} else {
|
||||
interface_configure($interface);
|
||||
interface_configure($interface, true);
|
||||
}
|
||||
header(url_safe('Location: /status_interfaces.php'));
|
||||
exit;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user