common: use pkgs.fetchgit and git commit hash for authorized keys repo
Do this to be in line with other places, where resources get fetched using git and to hopefully avoid errors such as: Cannot find Git revision 'da9d3ead9d97ce0fef7538638326264957e2f1b4' in ref 'trunk' of repository 'ssh://forgejo@git.hamburg.ccc.de/CCCHH/infrastructure-authorized-keys.git'! Please make sure that the rev exists on the ref you've specified or add allRefs = true; to fetchGit. This issue was discovered while trying to make the new hydra work.
This commit is contained in:
parent
fefff391b7
commit
ec64eebfd6
|
@ -9,10 +9,10 @@
|
||||||
{ config, pkgs, lib, ... }:
|
{ config, pkgs, lib, ... }:
|
||||||
|
|
||||||
let
|
let
|
||||||
authorizedKeysRepo = builtins.fetchGit {
|
authorizedKeysRepo = pkgs.fetchgit {
|
||||||
url = "forgejo@git.hamburg.ccc.de:CCCHH/infrastructure-authorized-keys.git";
|
url = "https://git.hamburg.ccc.de/CCCHH/infrastructure-authorized-keys";
|
||||||
ref = "trunk";
|
rev = "b6a29dc7af0a45a8c0b4904290c7cb0c5bc51413";
|
||||||
rev = "da9d3ead9d97ce0fef7538638326264957e2f1b4";
|
hash = "sha256-c0aH0wQeJtfXJG5wAbS6aO8yILLI1NNkFAHAeOm8RXA=";
|
||||||
};
|
};
|
||||||
authorizedKeys = builtins.filter (item: item != "") (lib.strings.splitString "\n" (builtins.readFile "${authorizedKeysRepo}/authorized_keys"));
|
authorizedKeys = builtins.filter (item: item != "") (lib.strings.splitString "\n" (builtins.readFile "${authorizedKeysRepo}/authorized_keys"));
|
||||||
in
|
in
|
||||||
|
|
Loading…
Reference in a new issue