From 2b01d479d81f91fd0713a58fd521a174f447abf7 Mon Sep 17 00:00:00 2001 From: Jean-Paul Calderone <exarkun@twistedmatrix.com> Date: Thu, 2 Sep 2021 12:36:38 -0400 Subject: [PATCH] Adopt the Nix packaging from our nixpkgs fork and use it --- nixos/modules/issuer.nix | 5 ++--- nixos/pkgs/zkapissuer/repo.nix | 7 +++++++ nixos/pkgs/zkapissuer/zkapissuer.nix | 5 +++++ 3 files changed, 14 insertions(+), 3 deletions(-) create mode 100644 nixos/pkgs/zkapissuer/repo.nix create mode 100644 nixos/pkgs/zkapissuer/zkapissuer.nix diff --git a/nixos/modules/issuer.nix b/nixos/modules/issuer.nix index ce1f928b..3ec5a147 100644 --- a/nixos/modules/issuer.nix +++ b/nixos/modules/issuer.nix @@ -2,8 +2,7 @@ # ZKAPs. { lib, pkgs, config, ... }: let cfg = config.services.private-storage-issuer; - # Our own nixpkgs fork: - ourpkgs = import ../../nixpkgs-ps.nix {}; + zkapissuer = import ../pkgs/zkapissuer {}; in { imports = [ # Give it a good SSH configuration. @@ -13,7 +12,7 @@ in { options = { services.private-storage-issuer.enable = lib.mkEnableOption "PrivateStorage ZKAP Issuer Service"; services.private-storage-issuer.package = lib.mkOption { - default = ourpkgs.zkapissuer.components.exes."PaymentServer-exe"; + default = zkapissuer.components.exes."PaymentServer-exe"; type = lib.types.package; example = lib.literalExample "pkgs.zkapissuer.components.exes.\"PaymentServer-exe\""; description = '' diff --git a/nixos/pkgs/zkapissuer/repo.nix b/nixos/pkgs/zkapissuer/repo.nix new file mode 100644 index 00000000..52decb88 --- /dev/null +++ b/nixos/pkgs/zkapissuer/repo.nix @@ -0,0 +1,7 @@ +{ fetchFromGitHub }: +fetchFromGitHub { + owner = "PrivateStorageio"; + repo = "PaymentServer"; + rev = "2ca189c51a5314eb476d1866d28ee483701af6f5"; + sha256 = "1sb53lvi6alwdjhx4cv1gg7ywkqf18n1zjgdj3nigq3vjwxhdcpb"; +} diff --git a/nixos/pkgs/zkapissuer/zkapissuer.nix b/nixos/pkgs/zkapissuer/zkapissuer.nix new file mode 100644 index 00000000..27f5fa3d --- /dev/null +++ b/nixos/pkgs/zkapissuer/zkapissuer.nix @@ -0,0 +1,5 @@ +{ callPackage }: +let + repo = callPackage ./repo.nix { }; +in + (import "${repo}/nix").PaymentServer -- GitLab