about summary refs log tree commit diff
path: root/packages/slocalc/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'packages/slocalc/default.nix')
-rw-r--r--packages/slocalc/default.nix25
1 files changed, 25 insertions, 0 deletions
diff --git a/packages/slocalc/default.nix b/packages/slocalc/default.nix
new file mode 100644
index 0000000..114120e
--- /dev/null
+++ b/packages/slocalc/default.nix
@@ -0,0 +1,25 @@
+{ lib, python3, stdenvNoCC }:
+
+stdenvNoCC.mkDerivation rec {
+  pname = "slocalc";
+  src = ./slocalc.py;
+  version = "0.1.0";
+
+  buildInputs = [ python3 ];
+  propagatedBuildInputs = [ python3 ];
+
+  dontUnpack = true;
+  dontBuild = true;
+
+  installPhase = ''
+    mkdir -p $out/bin
+    cp $src $out/bin/${pname}
+  '';
+
+  meta = with lib; {
+    description = "Calculate SLO uptime.";
+    license = with licenses; [ mit ];
+    platforms = platforms.unix;
+    maintainers = with maintainers; [ fcuny ];
+  };
+}