diff --git a/nixos/modules/system/activation/switch-to-configuration.pl b/nixos/modules/system/activation/switch-to-configuration.pl index 7bce06cf3b5a..12012698efe3 100644 --- a/nixos/modules/system/activation/switch-to-configuration.pl +++ b/nixos/modules/system/activation/switch-to-configuration.pl @@ -188,7 +188,7 @@ while (my ($unit, $state) = each %{$activePrev}) { if (boolIsTrue($unitInfo->{'X-ReloadIfChanged'} // "no")) { write_file($reloadListFile, { append => 1 }, "$unit\n"); } - elsif (!boolIsTrue($unitInfo->{'X-RestartIfChanged'} // "yes")) { + elsif (!boolIsTrue($unitInfo->{'X-RestartIfChanged'} // "yes") || boolIsTrue($unitInfo->{'RefuseManualStop'} // "no") ) { push @unitsToSkip, $unit; } else { # If this unit is socket-activated, then stop the