From 29029695329826ce04b57ee73cae2d87c7e7c7e7 Mon Sep 17 00:00:00 2001 From: Wolfgang Walther Date: Sun, 16 Mar 2025 20:26:01 +0100 Subject: [PATCH] postgresqlPackages.pg_auto_failover: modernize --- .../sql/postgresql/ext/pg_auto_failover.nix | 20 +++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/pkgs/servers/sql/postgresql/ext/pg_auto_failover.nix b/pkgs/servers/sql/postgresql/ext/pg_auto_failover.nix index 0d43faa7fe2e..dbb723e31049 100644 --- a/pkgs/servers/sql/postgresql/ext/pg_auto_failover.nix +++ b/pkgs/servers/sql/postgresql/ext/pg_auto_failover.nix @@ -1,9 +1,9 @@ { - lib, - stdenv, - fetchFromGitHub, - postgresql, buildPostgresqlExtension, + fetchFromGitHub, + lib, + postgresql, + stdenv, }: buildPostgresqlExtension rec { @@ -12,23 +12,23 @@ buildPostgresqlExtension rec { src = fetchFromGitHub { owner = "citusdata"; - repo = pname; - rev = "v${version}"; - sha256 = "sha256-OIWykfFbVskrkPG/zSmZtZjc+W956KSfIzK7f5QOqpI="; + repo = "pg_auto_failover"; + tag = "v${version}"; + hash = "sha256-OIWykfFbVskrkPG/zSmZtZjc+W956KSfIzK7f5QOqpI="; }; buildInputs = postgresql.buildInputs; - meta = with lib; { + meta = { description = "PostgreSQL extension and service for automated failover and high-availability"; mainProgram = "pg_autoctl"; homepage = "https://github.com/citusdata/pg_auto_failover"; changelog = "https://github.com/citusdata/pg_auto_failover/blob/v${version}/CHANGELOG.md"; maintainers = [ ]; platforms = postgresql.meta.platforms; - license = licenses.postgresql; + license = lib.licenses.postgresql; # PostgreSQL 17 support issue upstream: https://github.com/hapostgres/pg_auto_failover/issues/1048 # Check after next package update. - broken = versionAtLeast postgresql.version "17" && version == "2.1"; + broken = lib.versionAtLeast postgresql.version "17" && version == "2.1"; }; }