apply statix simplication
This commit is contained in:
parent
ee8f7e82b8
commit
1ac5f25092
5 changed files with 4 additions and 5 deletions
2
ci.nix
2
ci.nix
|
@ -4,7 +4,7 @@
|
|||
}:
|
||||
let
|
||||
self = builtins.getFlake (toString ./.);
|
||||
nixpkgs = self.inputs.nixpkgs;
|
||||
inherit (self.inputs) nixpkgs;
|
||||
stripDomain = name: nixpkgs.lib.head (builtins.match "(.*).nix-community.org" name);
|
||||
in
|
||||
(nixpkgs.lib.mapAttrs' (name: config: nixpkgs.lib.nameValuePair "nixos-${stripDomain name}" config.config.system.build.toplevel) self.outputs.nixosConfigurations) //
|
||||
|
|
|
@ -4,7 +4,7 @@ let
|
|||
owner = "hercules-ci-agent";
|
||||
sopsFile = ./secrets.yaml;
|
||||
};
|
||||
secrets = config.sops.secrets;
|
||||
inherit (config.sops) secrets;
|
||||
in
|
||||
{
|
||||
sops.secrets."binary-caches.json" = herculesSecret;
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
{ ... }:
|
||||
{
|
||||
# Make sure that the firewall is enabled, even if it's the default.
|
||||
networking.firewall.enable = true;
|
||||
|
|
|
@ -99,7 +99,7 @@ in
|
|||
"hydra.nix-community.org" = {
|
||||
forceSSL = true;
|
||||
enableACME = true;
|
||||
locations."/".proxyPass = "http://localhost:${toString (config.services.hydra.port)}";
|
||||
locations."/".proxyPass = "http://localhost:${toString config.services.hydra.port}";
|
||||
};
|
||||
};
|
||||
|
||||
|
|
|
@ -9,7 +9,7 @@ in
|
|||
let
|
||||
chars = lib.stringToCharacters (builtins.substring 0 4 id);
|
||||
n = builtins.map (c: lib.mod (ord c) 10) chars;
|
||||
s = builtins.concatStringsSep "" (builtins.map (i: builtins.toString i) n);
|
||||
s = builtins.concatStringsSep "" (builtins.map builtins.toString n);
|
||||
in
|
||||
assert builtins.stringLength id >= 4;
|
||||
assert builtins.length chars == 4;
|
||||
|
|
Loading…
Add table
Reference in a new issue