Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: NixOS/nixpkgs
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 71c19d3efaa2
Choose a base ref
...
head repository: NixOS/nixpkgs
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: b54c60b68951
Choose a head ref
  • 1 commit
  • 1 file changed
  • 1 contributor

Commits on Jan 21, 2020

  1. nixos/zerotierone: simplify the unit

    There is no need to stop/start the unit when the machine is online or
    offline.
    
    This should fix the shutdown locking issues.
    
    nixos zerotier: sometimes it doesn't shutdown
    zimbatm committed Jan 21, 2020

    Verified

    This commit was signed with the committer’s verified signature. The key has expired.
    dtzWill Will Dietz
    Copy the full SHA
    b54c60b View commit details
Showing with 7 additions and 3 deletions.
  1. +7 −3 nixos/modules/services/networking/zerotierone.nix
10 changes: 7 additions & 3 deletions nixos/modules/services/networking/zerotierone.nix
Original file line number Diff line number Diff line change
@@ -38,10 +38,13 @@ in
config = mkIf cfg.enable {
systemd.services.zerotierone = {
description = "ZeroTierOne";
path = [ cfg.package ];
bindsTo = [ "network-online.target" ];
after = [ "network-online.target" ];

wantedBy = [ "multi-user.target" ];
after = [ "network.target" ];
wants = [ "network-online.target" ];

path = [ cfg.package ];

preStart = ''
mkdir -p /var/lib/zerotier-one/networks.d
chmod 700 /var/lib/zerotier-one
@@ -53,6 +56,7 @@ in
ExecStart = "${cfg.package}/bin/zerotier-one -p${toString cfg.port}";
Restart = "always";
KillMode = "process";
TimeoutStopSec = 5;
};
};