nix: module: set max-jobs to "auto" and cores to 0

This commit is contained in:
Bloxx12 2025-06-02 17:18:22 +02:00
commit b98c824f87
Signed by: faukah
SSH key fingerprint: SHA256:Uj2AXqvtdCA4hn5Hq0ZonhIAyUqI1q4w2sMG3Z1TH7E

View file

@ -51,6 +51,9 @@ in {
dates = ["21:00"];
};
# NOTE:
# Writes the settings to /etc/nix/nix.conf.
# See `man nix.conf` for more detailed descriptions of these settings.
settings = {
# Tell nix to use the xdg spec for base directories
# while transitioning, any state must be carried over
@ -69,7 +72,14 @@ in {
# Let the system decide the number of max jobs
# based on available system specs. Usually this is
# the same as the number of cores your CPU has.
max-jobs = 2;
max-jobs = "auto";
# This option defines the maximum number of concurrent tasks during one build.
# It affects, e.g., -j option for make. The special value 0 means that the builder
# should use all available CPU cores in the system. Some builds may become
# non-deterministic with this option; use with care!
# Packages will only be affected if enableParallelBuilding is set for them.
cores = 0;
# If set, Nix will perform builds in a sandboxed environment
# that it will set up automatically for each build.