44 lines
1009 B
Nix
44 lines
1009 B
Nix
{inputs, pkgs, ...}: {
|
|
imports = [
|
|
./hardening.nix
|
|
./limits.nix
|
|
./networking.nix
|
|
./boot
|
|
];
|
|
|
|
# Ensure root login is available on every machine (if ssh is enabled)
|
|
users.users.root.openssh.authorizedKeys.keys = import ../../keys/ssh.nix;
|
|
|
|
# Speed up the build a little bit, these aren't really needed
|
|
documentation = {
|
|
enable = false;
|
|
info.enable = false;
|
|
man.enable = false;
|
|
doc.enable = false;
|
|
nixos.enable = false;
|
|
};
|
|
|
|
# Immutable users
|
|
users.mutableUsers = false;
|
|
|
|
### Nix settings ###
|
|
nix = {
|
|
# Make sure flakes are enabled
|
|
settings.experimental-features = ["nix-command" "flakes"];
|
|
extraOptions = ''
|
|
keep-outputs = true
|
|
keep-derivations = true
|
|
|
|
flake-registry = ${builtins.toFile "flake-registry" (builtins.toJSON {
|
|
version = 2;
|
|
flakes = [];
|
|
})}
|
|
'';
|
|
nixPath = ["nixpkgs=${pkgs.path}"];
|
|
registry = {
|
|
self.flake = inputs.self;
|
|
nixpkgs.flake = inputs.nixpkgs;
|
|
};
|
|
};
|
|
}
|