summaryrefslogtreecommitdiff
path: root/overlays/smartprom/default.nix
blob: 0dd0771b7d139dc3705c9719e5f352cbb52db54b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
{ final, prev, flakeInputs, sources, ... }:
{
  smartprom = flakeInputs.mach-nix.lib.${final.system}.buildPythonPackage rec {
    inherit (sources.smartprom) src pname version;
    ignoreDataOutdated = true;

    prePatch = ''
      mkdir smartprom
      mv smartprom.py smartprom/__main__.py
      echo >> smartprom/__init__.py

      substituteAll ${./setup.py} ./setup.py
    '';

    requirements = ''
      prometheus_client
    '';
  };
}