1
0
Fork 0
mirror of https://github.com/LnL7/nix-darwin.git synced 2025-03-13 20:30:02 +00:00

nix: show warning when using distributed builds without services.activate-system

This commit is contained in:
Daiderd Jordan 2017-02-19 13:32:22 +01:00
parent 74c27037e6
commit 7047071266
No known key found for this signature in database
GPG key ID: D02435D05B810C96

View file

@ -19,11 +19,11 @@ let
# WARNING: this file is generated from the nix.* options in
# your NixOS configuration, typically
# /etc/nixos/configuration.nix. Do not edit it!
${optionalString (config.services.nix-daemon.enable) ''
${optionalString config.services.nix-daemon.enable ''
build-users-group = nixbld
''}
build-max-jobs = ${toString (cfg.maxJobs)}
build-cores = ${toString (cfg.buildCores)}
build-max-jobs = ${toString cfg.maxJobs}
build-cores = ${toString cfg.buildCores}
build-use-sandbox = ${if (builtins.isBool cfg.useSandbox) then (if cfg.useSandbox then "true" else "false") else cfg.useSandbox}
${optionalString (cfg.sandboxPaths != []) ''
build-sandbox-paths = ${toString cfg.sandboxPaths}
@ -304,6 +304,9 @@ in
config = {
warnings = mkIf (!config.services.activate-system.enable && cfg.distributedBuilds)
[ "services.activate-system is not enabled, a reboot could cause distributed builds to stop working." ];
nix.binaryCachePublicKeys = [ "cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY=" ];
environment.etc."nix/nix.conf".source = nixConf;