0
0
Fork 0
mirror of https://github.com/NixOS/nixpkgs.git synced 2025-07-13 21:50:33 +03:00

Merge pull request #242116 from flurie/fix-datadog-agent

datadog-agent: 7.38.1 -> 7.45.1
This commit is contained in:
Mario Rodas 2023-08-10 20:53:27 -05:00 committed by GitHub
commit d8001aae54
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 17 additions and 5 deletions

View file

@ -153,6 +153,18 @@ in {
type = types.bool; type = types.bool;
}; };
processAgentPackage = mkOption {
default = pkgs.datadog-process-agent;
defaultText = literalExpression "pkgs.datadog-process-agent";
description = lib.mdDoc ''
Which DataDog v7 agent package to use. Note that the provided
package is expected to have an overridable `pythonPackages`-attribute
which configures the Python environment with the Datadog
checks.
'';
type = types.package;
};
enableTraceAgent = mkOption { enableTraceAgent = mkOption {
description = lib.mdDoc '' description = lib.mdDoc ''
Whether to enable the trace agent. Whether to enable the trace agent.
@ -270,7 +282,7 @@ in {
path = [ ]; path = [ ];
script = '' script = ''
export DD_API_KEY=$(head -n 1 ${cfg.apiKeyFile}) export DD_API_KEY=$(head -n 1 ${cfg.apiKeyFile})
${pkgs.datadog-process-agent}/bin/process-agent --config /etc/datadog-agent/datadog.yaml ${cfg.processAgentPackage}/bin/process-agent --config /etc/datadog-agent/datadog.yaml
''; '';
}); });

View file

@ -1,7 +1,7 @@
{ lib { lib
, stdenv , stdenv
, cmake , cmake
, buildGoModule , buildGo118Module
, makeWrapper , makeWrapper
, fetchFromGitHub , fetchFromGitHub
, pythonPackages , pythonPackages
@ -14,12 +14,12 @@
let let
# keep this in sync with github.com/DataDog/agent-payload dependency # keep this in sync with github.com/DataDog/agent-payload dependency
payloadVersion = "4.78.0"; payloadVersion = "5.0.89";
python = pythonPackages.python; python = pythonPackages.python;
owner = "DataDog"; owner = "DataDog";
repo = "datadog-agent"; repo = "datadog-agent";
goPackagePath = "github.com/${owner}/${repo}"; goPackagePath = "github.com/${owner}/${repo}";
version = "7.38.1"; version = "7.45.1";
src = fetchFromGitHub { src = fetchFromGitHub {
inherit owner repo; inherit owner repo;
@ -35,7 +35,7 @@ let
cmakeFlags = ["-DBUILD_DEMO=OFF" "-DDISABLE_PYTHON2=ON"]; cmakeFlags = ["-DBUILD_DEMO=OFF" "-DDISABLE_PYTHON2=ON"];
}; };
in buildGoModule rec { in buildGo118Module rec {
pname = "datadog-agent"; pname = "datadog-agent";
inherit src version; inherit src version;