Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at fix-function-merge 32 lines 1.1 kB view raw
1{ lib, stdenv, fetchFromGitHub, postgresql, openssl, zlib, readline, libkrb5, libxcrypt }: 2 3stdenv.mkDerivation rec { 4 pname = "pg_auto_failover"; 5 version = "2.1"; 6 7 src = fetchFromGitHub { 8 owner = "citusdata"; 9 repo = pname; 10 rev = "v${version}"; 11 sha256 = "sha256-OIWykfFbVskrkPG/zSmZtZjc+W956KSfIzK7f5QOqpI="; 12 }; 13 14 buildInputs = postgresql.buildInputs ++ [ postgresql ]; 15 16 installPhase = '' 17 install -D -t $out/bin src/bin/pg_autoctl/pg_autoctl 18 install -D -t $out/lib src/monitor/pgautofailover.so 19 install -D -t $out/share/postgresql/extension src/monitor/*.sql 20 install -D -t $out/share/postgresql/extension src/monitor/pgautofailover.control 21 ''; 22 23 meta = with lib; { 24 description = "PostgreSQL extension and service for automated failover and high-availability"; 25 mainProgram = "pg_autoctl"; 26 homepage = "https://github.com/citusdata/pg_auto_failover"; 27 changelog = "https://github.com/citusdata/pg_auto_failover/blob/v${version}/CHANGELOG.md"; 28 maintainers = [ ]; 29 platforms = postgresql.meta.platforms; 30 license = licenses.postgresql; 31 }; 32}