Commit a858b479 authored by Franco Fichtner's avatar Franco Fichtner

system: fix faulty revert; rc.sshd is clever on it's own

parent c2933dc2
...@@ -240,6 +240,7 @@ if ($_SERVER['REQUEST_METHOD'] === 'GET') { ...@@ -240,6 +240,7 @@ if ($_SERVER['REQUEST_METHOD'] === 'GET') {
setup_serial_port(); setup_serial_port();
system_hosts_generate(); system_hosts_generate();
// Restart DNS in case dns rebinding toggled // Restart DNS in case dns rebinding toggled
if (isset($config['dnsmasq']['enable'])) { if (isset($config['dnsmasq']['enable'])) {
services_dnsmasq_configure(); services_dnsmasq_configure();
...@@ -248,17 +249,13 @@ if ($_SERVER['REQUEST_METHOD'] === 'GET') { ...@@ -248,17 +249,13 @@ if ($_SERVER['REQUEST_METHOD'] === 'GET') {
} }
if ($restart_sshd) { if ($restart_sshd) {
configd_run("sshd stop"); log_error(gettext('Secure Shell configuration has changed. Applying now...'));
log_error(gettext("secure shell configuration has changed. Stopping sshd.")); configd_run('sshd restart', true);
if ($config['system']['ssh']['enabled']) {
log_error(gettext("secure shell configuration has changed. Restarting sshd."));
mwexec_bg('/usr/local/etc/rc.restart_webgui 2');
}
} }
if ($restart_webgui) { if ($restart_webgui) {
log_error(gettext("webConfigurator configuration has changed. Restarting webConfigurator.")); log_error(gettext('webConfigurator configuration has changed. Applying now...'));
configd_run("webgui restart 2", true); mwexec_bg('/usr/local/etc/rc.restart_webgui 2');
} }
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment