3
0
Fork 0
forked from mirrors/nixpkgs

Revert "nixos/switch-to-configuration: restart changed socket units"

This reverts commit 89806e9536.

See #74626
This commit is contained in:
Domen Kožar 2019-11-30 13:46:57 +01:00
parent ebe27d6503
commit 0f799bd8a4
No known key found for this signature in database
GPG key ID: C2FFBCAFD2C24246

View file

@ -214,17 +214,7 @@ while (my ($unit, $state) = each %{$activePrev}) {
# Reload the changed mount unit to force a remount. # Reload the changed mount unit to force a remount.
$unitsToReload{$unit} = 1; $unitsToReload{$unit} = 1;
recordUnit($reloadListFile, $unit); recordUnit($reloadListFile, $unit);
} elsif ($unit =~ /\.socket$/) { } elsif ($unit =~ /\.socket$/ || $unit =~ /\.path$/ || $unit =~ /\.slice$/) {
my $unitInfo = parseUnit($newUnitFile);
# If a socket unit has been changed, the corresponding
# service unit has to be stopped before the socket can
# be restarted. The service will be started again on demand.
my $serviceUnit = $unitInfo->{'Unit'} // "$baseName.service";
$unitsToStop{$serviceUnit} = 1;
$unitsToStop{$unit} = 1;
$unitsToStart{$unit} = 1;
recordUnit($startListFile, $unit);
} elsif ($unit =~ /\.path$/ || $unit =~ /\.slice$/) {
# FIXME: do something? # FIXME: do something?
} else { } else {
my $unitInfo = parseUnit($newUnitFile); my $unitInfo = parseUnit($newUnitFile);