summary refs log tree commit diff
path: root/pkgs/tools/networking
diff options
context:
space:
mode:
authorRodney Lorrimar <dev@rodney.id.au>2018-05-27 14:52:24 +0100
committerVincent Ambo <mail@tazj.in>2018-08-09 16:53:30 +0200
commitfb6679151a7bd0d9ecc485cc7e0524b82a2adf01 (patch)
tree56133b1a196132657d11ad28bfbc2d7e2a5163fb /pkgs/tools/networking
parent3a195dc2efaec5dc100f0122084460fdf24607d6 (diff)
downloadnixlib-fb6679151a7bd0d9ecc485cc7e0524b82a2adf01.tar
nixlib-fb6679151a7bd0d9ecc485cc7e0524b82a2adf01.tar.gz
nixlib-fb6679151a7bd0d9ecc485cc7e0524b82a2adf01.tar.bz2
nixlib-fb6679151a7bd0d9ecc485cc7e0524b82a2adf01.tar.lz
nixlib-fb6679151a7bd0d9ecc485cc7e0524b82a2adf01.tar.xz
nixlib-fb6679151a7bd0d9ecc485cc7e0524b82a2adf01.tar.zst
nixlib-fb6679151a7bd0d9ecc485cc7e0524b82a2adf01.zip
datadog-integrations-core: init at git-2018-05-27
Diffstat (limited to 'pkgs/tools/networking')
-rw-r--r--pkgs/tools/networking/dd-agent/integrations-core.nix66
1 files changed, 66 insertions, 0 deletions
diff --git a/pkgs/tools/networking/dd-agent/integrations-core.nix b/pkgs/tools/networking/dd-agent/integrations-core.nix
new file mode 100644
index 000000000000..2efc82473690
--- /dev/null
+++ b/pkgs/tools/networking/dd-agent/integrations-core.nix
@@ -0,0 +1,66 @@
+{ pkgs
+, python
+, overrides ? (self: super: {})
+}:
+
+with pkgs.lib;
+
+let
+  src = pkgs.fetchFromGitHub {
+    owner = "DataDog";
+    repo = "integrations-core";
+    rev = "7be76e73969a8b9c993903681b300e1dd32f4b4d";
+    sha256 = "1qsqzm5iswgv9jrflh5mvbz9a7js7jf42cb28lzdzsp45iwfs2aa";
+  };
+  version = "git-2018-05-27";
+
+  buildIntegration = { pname, ... }@args: python.pkgs.buildPythonPackage (args // {
+    inherit src version;
+    name = "datadog-integration-${pname}-${version}";
+
+    postPatch = ''
+      # jailbreak install_requires
+      sed -i 's/==.*//' requirements.in
+      cp requirements.in requirements.txt
+    '';
+    sourceRoot = "source/${args.sourceRoot or pname}";
+    doCheck = false;
+  });
+
+  packages = (self: {
+    python = python.withPackages (ps: with self; [ disk network postgres nginx mongo ]);
+
+    datadog_checks_base = buildIntegration {
+      pname = "checks-base";
+      sourceRoot = "datadog_checks_base";
+      propagatedBuildInputs = with self; with python.pkgs; [ requests protobuf prometheus_client uuid simplejson uptime ];
+    };
+
+    disk = buildIntegration {
+      pname = "disk";
+      propagatedBuildInputs = with self; with python.pkgs; [ datadog_checks_base psutil ];
+    };
+
+    network = buildIntegration {
+      pname = "network";
+      propagatedBuildInputs = with self; with python.pkgs; [ datadog_checks_base psutil ];
+    };
+
+    postgres = buildIntegration {
+      pname = "postgres";
+      propagatedBuildInputs = with self; with python.pkgs; [ datadog_checks_base pg8000 psycopg2 ];
+    };
+
+    nginx = buildIntegration {
+      pname = "nginx";
+      propagatedBuildInputs = with self; with python.pkgs; [ datadog_checks_base ];
+    };
+
+    mongo = buildIntegration {
+      pname = "mongo";
+      propagatedBuildInputs = with self; with python.pkgs; [ datadog_checks_base pymongo ];
+    };
+
+  });
+
+in fix' (extends overrides packages)