treewide: format using nixfmt
Signed-off-by: Bloxx12 <charlie@charlieroot.dev> Change-Id: I6a6a69641c36f9763e104087a559c148d0449f00
This commit is contained in:
parent
f4464732e3
commit
e641dfa114
113 changed files with 1545 additions and 1019 deletions
|
@ -4,9 +4,12 @@
|
|||
pkgs,
|
||||
sources,
|
||||
...
|
||||
}: let
|
||||
determinate = (import sources.flake-compat {src = sources.determinate;}).outputs;
|
||||
dix = (import sources.flake-compat {src = determinate.inputs.nix;}).outputs.packages.${pkgs.stdenv.system}.nix;
|
||||
}:
|
||||
let
|
||||
determinate = (import sources.flake-compat { src = sources.determinate; }).outputs;
|
||||
dix =
|
||||
(import sources.flake-compat { src = determinate.inputs.nix; })
|
||||
.outputs.packages.${pkgs.stdenv.system}.nix;
|
||||
|
||||
# Stronger than mkDefault (1000), weaker than mkForce (50) and the "default override priority"
|
||||
# (100).
|
||||
|
@ -14,7 +17,8 @@
|
|||
|
||||
# Stronger than the "default override priority", as the upstream module uses that, and weaker than mkForce (50).
|
||||
mkMorePreferable = lib.mkOverride 75;
|
||||
in {
|
||||
in
|
||||
{
|
||||
config = {
|
||||
nix = {
|
||||
package = dix;
|
||||
|
@ -30,7 +34,9 @@ in {
|
|||
services.nix-daemon.serviceConfig = {
|
||||
ExecStart = [
|
||||
""
|
||||
"@${determinate.packages.${pkgs.stdenv.system}.default}/bin/determinate-nixd determinate-nixd --nix-bin ${config.nix.package}/bin daemon"
|
||||
"@${
|
||||
determinate.packages.${pkgs.stdenv.system}.default
|
||||
}/bin/determinate-nixd determinate-nixd --nix-bin ${config.nix.package}/bin daemon"
|
||||
];
|
||||
KillMode = mkPreferable "process";
|
||||
LimitNOFILE = mkMorePreferable 1048576;
|
||||
|
@ -41,11 +47,14 @@ in {
|
|||
nix-daemon.socketConfig.FileDescriptorName = "nix-daemon.socket";
|
||||
determinate-nixd = {
|
||||
description = "Determinate Nixd Daemon Socket";
|
||||
wantedBy = ["sockets.target"];
|
||||
before = ["multi-user.target"];
|
||||
wantedBy = [ "sockets.target" ];
|
||||
before = [ "multi-user.target" ];
|
||||
|
||||
unitConfig = {
|
||||
RequiresMountsFor = ["/nix/store" "/nix/var/determinate"];
|
||||
RequiresMountsFor = [
|
||||
"/nix/store"
|
||||
"/nix/var/determinate"
|
||||
];
|
||||
};
|
||||
|
||||
socketConfig = {
|
||||
|
|
|
@ -5,10 +5,12 @@
|
|||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}: let
|
||||
}:
|
||||
let
|
||||
inherit (lib.attrsets) mapAttrsToList;
|
||||
inherit (lib.modules) mkForce;
|
||||
in {
|
||||
in
|
||||
{
|
||||
nix = {
|
||||
# Check that Nix can parse the generated nix.conf.
|
||||
checkConfig = true;
|
||||
|
@ -46,7 +48,7 @@ in {
|
|||
# Automatically optimize nix store by removing hard links
|
||||
optimise = {
|
||||
automatic = true;
|
||||
dates = ["21:00"];
|
||||
dates = [ "21:00" ];
|
||||
};
|
||||
|
||||
# NOTE:
|
||||
|
@ -62,10 +64,18 @@ in {
|
|||
auto-optimise-store = true;
|
||||
|
||||
# Users that are allowed to connect to the Nix daemon.
|
||||
allowed-users = ["root" "@wheel" "nix-builder"];
|
||||
allowed-users = [
|
||||
"root"
|
||||
"@wheel"
|
||||
"nix-builder"
|
||||
];
|
||||
|
||||
# Users that are allowed to connect to the Nix daemon.
|
||||
trusted-users = ["root" "@wheel" "nix-builder"];
|
||||
trusted-users = [
|
||||
"root"
|
||||
"@wheel"
|
||||
"nix-builder"
|
||||
];
|
||||
|
||||
# Let the system decide the number of max jobs
|
||||
# based on available system specs. Usually this is
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
# taken from raf
|
||||
{sources, ...}: {
|
||||
{ sources, ... }:
|
||||
{
|
||||
# Global nixpkgs configuration.
|
||||
# This is ignored if nixpkgs.pkgs is set, which should be avoided.
|
||||
nixpkgs = {
|
||||
|
@ -40,7 +41,7 @@
|
|||
|
||||
# List of derivation warnings to display while rebuilding.
|
||||
# See: <https://github.com/NixOS/nixpkgs/blob/master/pkgs/stdenv/generic/check-meta.nix>
|
||||
showDerivationWarnings = [];
|
||||
showDerivationWarnings = [ ];
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue