From fc467dc475567cf8030d5b20aacf99f2afcbbe9e Mon Sep 17 00:00:00 2001 From: Alejandro Soto Date: Mon, 9 Mar 2026 15:25:05 -0600 Subject: trivionomicon: athena-bccr: add support for mirrors --- modules/athena-bccr/hm.nix | 7 ++++++- modules/athena-bccr/options.nix | 12 ++++++++++++ modules/athena-bccr/sys.nix | 8 +++++++- 3 files changed, 25 insertions(+), 2 deletions(-) (limited to 'modules/athena-bccr') diff --git a/modules/athena-bccr/hm.nix b/modules/athena-bccr/hm.nix index 0678e3c..df41f12 100644 --- a/modules/athena-bccr/hm.nix +++ b/modules/athena-bccr/hm.nix @@ -5,7 +5,12 @@ doctrine, ... }: let - athena = pkgs.${doctrine.prefix}.athena-bccr.${cfg.release}; + athena = + (pkgs.${doctrine.prefix}.athena-bccr.override { + inherit (cfg) mirror; + }).${ + cfg.release + }; in { home.packages = [ athena.firmador diff --git a/modules/athena-bccr/options.nix b/modules/athena-bccr/options.nix index eb61cf5..7b6cf93 100644 --- a/modules/athena-bccr/options.nix +++ b/modules/athena-bccr/options.nix @@ -7,6 +7,12 @@ with lib.types; { description = "hash of the Gaudi client"; }; + mirror = lib.mkOption { + type = nullOr str; + default = null; + description = "release zip mirror base URL, if null then the release zip must be manually added to the Nix store"; + }; + release = lib.mkOption { type = str; default = "latest"; @@ -21,6 +27,12 @@ with lib.types; { description = "user group with full access to the smartcard reader"; }; + mirror = lib.mkOption { + type = nullOr str; + default = null; + description = "release zip mirror base URL, if null then the release zip must be manually added to the Nix store"; + }; + release = lib.mkOption { type = str; default = "latest"; diff --git a/modules/athena-bccr/sys.nix b/modules/athena-bccr/sys.nix index 98ae904..bd7d758 100644 --- a/modules/athena-bccr/sys.nix +++ b/modules/athena-bccr/sys.nix @@ -6,7 +6,13 @@ doctrine, ... }: let - athena = pkgs.${doctrine.prefix}.athena-bccr.${cfg.release}; + athena = + (pkgs.${doctrine.prefix}.athena-bccr.override { + inherit (cfg) mirror; + }).${ + cfg.release + }; + inherit (athena) vendor; driver = athena.card-driver.lib; -- cgit v1.2.3