get "hosts.baseline-x86_64" to eval
This commit is contained in:
@@ -19,7 +19,7 @@
|
|||||||
#
|
#
|
||||||
{ config, lib, pkgs, ... }:
|
{ config, lib, pkgs, ... }:
|
||||||
let
|
let
|
||||||
hostCfg = config.sane.hosts.by-name."${config.networking.hostName}";
|
hostCfg = config.sane.hosts.by-name."${config.networking.hostName}" or null;
|
||||||
bindCfg = config.services.bind;
|
bindCfg = config.services.bind;
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
@@ -50,7 +50,7 @@ in
|
|||||||
];
|
];
|
||||||
services.bind.listenOn = [
|
services.bind.listenOn = [
|
||||||
"127.0.0.1"
|
"127.0.0.1"
|
||||||
] ++ lib.optionals (hostCfg.wg-home.ip != null) [
|
] ++ lib.optionals (hostCfg != null && hostCfg.wg-home.ip != null) [
|
||||||
# allow wireguard clients to use us as a recursive resolver (only needed for servo)
|
# allow wireguard clients to use us as a recursive resolver (only needed for servo)
|
||||||
hostCfg.wg-home.ip
|
hostCfg.wg-home.ip
|
||||||
];
|
];
|
||||||
|
@@ -29,5 +29,12 @@ in
|
|||||||
# TODO: service sandboxing
|
# TODO: service sandboxing
|
||||||
services.btrfs.autoScrub.enable = lib.mkIf cfg.enabled true;
|
services.btrfs.autoScrub.enable = lib.mkIf cfg.enabled true;
|
||||||
services.btrfs.autoScrub.interval = "weekly";
|
services.btrfs.autoScrub.interval = "weekly";
|
||||||
|
|
||||||
|
# nixos/modules/tasks/filesystems/btrfs.nix fires this assertion, but its implementation totally handles the case of 0 btrfs filesystems.
|
||||||
|
sane.silencedAssertions = lib.mkIf cfg.enabled [''
|
||||||
|
If 'services.btrfs.autoScrub' is enabled, you need to have at least one
|
||||||
|
btrfs file system mounted via 'fileSystems' or specify a list manually
|
||||||
|
in 'services.btrfs.autoScrub.fileSystems'.
|
||||||
|
''];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user