From 668556331b78b67ca3278a6d7a33af9c6a392c7a Mon Sep 17 00:00:00 2001 From: Mateusz Kowalczyk Date: Sat, 3 Jun 2017 12:27:43 +0100 Subject: [PATCH] Revert "datadog: Properly use configured package." This reverts commit 50f53da9eff3e7a1686ff439b341ada5bd63ddcd. --- nixos/modules/services/monitoring/dd-agent/dd-agent.nix | 8 ++++---- pkgs/tools/networking/dd-agent/default.nix | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/nixos/modules/services/monitoring/dd-agent/dd-agent.nix b/nixos/modules/services/monitoring/dd-agent/dd-agent.nix index 04a21871519b..e55faed8e078 100644 --- a/nixos/modules/services/monitoring/dd-agent/dd-agent.nix +++ b/nixos/modules/services/monitoring/dd-agent/dd-agent.nix @@ -23,7 +23,7 @@ let etcfiles = map (i: { source = if builtins.hasAttr "config" i then pkgs.writeText "${i.name}.yaml" i.config - else "${cfg.agent}/agent/conf.d-system/${i.name}.yaml"; + else "${pkgs.dd-agent}/agent/conf.d-system/${i.name}.yaml"; target = "dd-agent/conf.d/${i.name}.yaml"; } ) cfg.integrations ++ @@ -119,13 +119,13 @@ in { path = [ cfg.agent pkgs.python pkgs.sysstat pkgs.procps ]; wantedBy = [ "multi-user.target" ]; serviceConfig = { - ExecStart = "${cfg.agent}/bin/dd-agent foreground"; + ExecStart = "${pkgs.dd-agent}/bin/dd-agent foreground"; User = "datadog"; Group = "datadog"; Restart = "always"; RestartSec = 2; }; - restartTriggers = [ cfg.agent ddConf ] ++ etcSources; + restartTriggers = [ pkgs.dd-agent ddConf ] ++ etcSources; }; systemd.services.dd-jmxfetch = lib.mkIf (builtins.any (i: i.name == "jmx") cfg.integrations) { @@ -133,7 +133,7 @@ in { path = [ cfg.agent pkgs.python pkgs.sysstat pkgs.procps pkgs.jdk ]; wantedBy = [ "multi-user.target" ]; serviceConfig = { - ExecStart = "${cfg.agent}/bin/dd-jmxfetch"; + ExecStart = "${pkgs.dd-agent}/bin/dd-jmxfetch"; User = "datadog"; Group = "datadog"; Restart = "always"; diff --git a/pkgs/tools/networking/dd-agent/default.nix b/pkgs/tools/networking/dd-agent/default.nix index 338804aa26b8..2556287570fd 100644 --- a/pkgs/tools/networking/dd-agent/default.nix +++ b/pkgs/tools/networking/dd-agent/default.nix @@ -5,7 +5,7 @@ # wrapper with their PYTHONPATH. This means overrideAttrs is not # strong enough (it overrides too late), we need to call it # beforehand. -, extraBuildInputs ? [ ] }: +, extraBuildInputs ? [ pythonPackages.psutil ] }: let inherit (pythonPackages) python; docker_1_10 = pythonPackages.buildPythonPackage rec {