Add a host for testing i_only_boot_zfs.
This commit is contained in:
28
nix/configuration/roles/dont_use_substituters/default.nix
Normal file
28
nix/configuration/roles/dont_use_substituters/default.nix
Normal file
@@ -0,0 +1,28 @@
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
|
||||
{
|
||||
imports = [ ];
|
||||
|
||||
options.me = {
|
||||
dont_use_substituters.enable = lib.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = false;
|
||||
example = true;
|
||||
description = "Whether we want to install dont_use_substituters.";
|
||||
};
|
||||
};
|
||||
|
||||
config = lib.mkIf config.me.dont_use_substituters.enable {
|
||||
# Disable substituters to avoid risk of cache poisoning.
|
||||
nix.extraOptions = ''
|
||||
substitute = false
|
||||
'';
|
||||
|
||||
nix.settings.substituters = lib.mkForce [ ];
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user