allows for specifying the public key directly
This makes it possible to use in pure mode
This commit is contained in:
parent
d308dd9b24
commit
8821e4aeaa
1 changed files with 14 additions and 5 deletions
17
module.nix
17
module.nix
|
@ -21,7 +21,7 @@ in
|
||||||
type = types.nullOr types.path;
|
type = types.nullOr types.path;
|
||||||
default = null;
|
default = null;
|
||||||
description = ''
|
description = ''
|
||||||
The private key to sign the derivations with.
|
File containing the private key to sign the derivations with.
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -29,7 +29,15 @@ in
|
||||||
type = types.nullOr types.path;
|
type = types.nullOr types.path;
|
||||||
default = null;
|
default = null;
|
||||||
description = ''
|
description = ''
|
||||||
The private key to sign the derivations with.
|
File containing the public key to sign the derivations with.
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
|
publicKey = lib.mkOption {
|
||||||
|
type = types.nullOr types.path;
|
||||||
|
default = null;
|
||||||
|
description = ''
|
||||||
|
The public key to sign the derivations with.
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -132,8 +140,9 @@ in
|
||||||
binaryCaches = [
|
binaryCaches = [
|
||||||
"http://127.0.0.1:12304/"
|
"http://127.0.0.1:12304/"
|
||||||
];
|
];
|
||||||
binaryCachePublicKeys = lib.mkIf (cfg.publicKeyFile != null) [
|
binaryCachePublicKeys = [
|
||||||
(builtins.readFile cfg.publicKeyFile)
|
lib.mkIf (cfg.publicKeyFile != null) (builtins.readFile cfg.publicKeyFile)
|
||||||
|
lib.mkIf (cfg.publicKey != null) cfg.publicKey
|
||||||
];
|
];
|
||||||
|
|
||||||
extraOptions = lib.mkIf (cfg.globalCacheTTL != null) ''
|
extraOptions = lib.mkIf (cfg.globalCacheTTL != null) ''
|
||||||
|
|
Loading…
Reference in a new issue