From 64fc63cc40f1b673651170e837356ab70d1930de Mon Sep 17 00:00:00 2001 From: Erik Arvstedt Date: Tue, 7 Apr 2020 23:04:57 +0200 Subject: [PATCH] remove pidFile - service type "simple" is the default - pidFile is not needed for service type "simple" --- modules/bitcoind.nix | 4 ---- 1 file changed, 4 deletions(-) diff --git a/modules/bitcoind.nix b/modules/bitcoind.nix index 409d264..376f3f9 100644 --- a/modules/bitcoind.nix +++ b/modules/bitcoind.nix @@ -5,7 +5,6 @@ with lib; let cfg = config.services.bitcoind; inherit (config) nix-bitcoin-services; - pidFile = "${cfg.dataDir}/bitcoind.pid"; configFile = pkgs.writeText "bitcoin.conf" '' ${optionalString cfg.testnet "testnet=1"} ${optionalString (cfg.dbCache != null) "dbcache=${toString cfg.dbCache}"} @@ -44,7 +43,6 @@ let ''; cmdlineOptions = concatMapStringsSep " " (arg: "'${arg}'") [ "-datadir=${cfg.dataDir}" - "-pid=${pidFile}" ]; hexStr = types.strMatching "[0-9a-f]+"; rpcUserOpts = { name, ... }: { @@ -282,11 +280,9 @@ in { done ''; serviceConfig = { - Type = "simple"; User = "${cfg.user}"; Group = "${cfg.group}"; ExecStart = "${cfg.package}/bin/bitcoind ${cmdlineOptions}"; - PIDFile = "${pidFile}"; Restart = "on-failure"; # Hardening measures