From 8d0ab40c56f51bb9dbbb91f2dcf73e3d6476f619 Mon Sep 17 00:00:00 2001 From: Franco Fichtner Date: Mon, 11 Nov 2024 12:32:54 +0100 Subject: [PATCH] mvc: always do stop/start on forced restart If 'nocheck' is used the service apears running and reload will do nothing. --- .../OPNsense/Base/ApiMutableServiceControllerBase.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/opnsense/mvc/app/controllers/OPNsense/Base/ApiMutableServiceControllerBase.php b/src/opnsense/mvc/app/controllers/OPNsense/Base/ApiMutableServiceControllerBase.php index f08a77fac..758ab60b4 100644 --- a/src/opnsense/mvc/app/controllers/OPNsense/Base/ApiMutableServiceControllerBase.php +++ b/src/opnsense/mvc/app/controllers/OPNsense/Base/ApiMutableServiceControllerBase.php @@ -200,7 +200,7 @@ abstract class ApiMutableServiceControllerBase extends ApiControllerBase if ($this->serviceEnabled()) { $runStatus = $this->statusAction(); - if ($runStatus['status'] != 'running') { + if ($runStatus['status'] != 'running' || $this->reconfigureForceRestart()) { $backend->configdRun(escapeshellarg(static::$internalServiceName) . ' start'); } else { $backend->configdRun(escapeshellarg(static::$internalServiceName) . ' reload');