mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-07-14 06:00:33 +03:00
nixos/network-interfaces: ensure correct ordering w.r.t. shutdown.target
Also, mark this service as `oneshot`, since it is.
This commit is contained in:
parent
e95b3d3915
commit
54064109fb
1 changed files with 3 additions and 1 deletions
|
@ -1408,9 +1408,11 @@ in
|
|||
|
||||
systemd.services.domainname = lib.mkIf (cfg.domain != null) {
|
||||
wantedBy = [ "sysinit.target" ];
|
||||
before = [ "sysinit.target" ];
|
||||
before = [ "sysinit.target" "shutdown.target" ];
|
||||
conflicts = [ "shutdown.target" ];
|
||||
unitConfig.DefaultDependencies = false;
|
||||
serviceConfig.ExecStart = ''${pkgs.nettools}/bin/domainname "${cfg.domain}"'';
|
||||
serviceConfig.Type = "oneshot";
|
||||
};
|
||||
|
||||
environment.etc.hostid = mkIf (cfg.hostId != null) { source = hostidFile; };
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue