nix-config/hosts/containers/nix-build/default.nix

63 lines
1.7 KiB
Nix
Raw Normal View History

{ hostRegistry, zentralwerk, config, pkgs, lib, ... }:
2021-10-03 16:19:37 +02:00
{
networking.hostName = "nix-build"; # Define your hostname.
networking.useDHCP = false;
networking.interfaces.enp6s18 = {
ipv4.addresses = [{
2022-01-16 13:26:37 +01:00
address = config.c3d2.hosts.nix-build.ip4;
prefixLength = zentralwerk.lib.config.site.net.c3d2.subnet4Len;
}];
useDHCP = false;
};
networking.defaultGateway = "172.22.99.1";
networking.firewall.allowedTCPPorts = [ 22 ];
networking.nameservers = [ "172.20.73.8" "9.9.9.9" ];
2021-10-03 16:19:37 +02:00
imports = [
./hardware-configuration.nix
];
boot = {
2021-10-31 18:59:46 +01:00
loader = {
systemd-boot.enable = true;
efi.efiSysMountPoint = "/boot";
};
2021-10-03 16:19:37 +02:00
tmpOnTmpfs = true;
2021-10-31 18:59:46 +01:00
cleanTmpDir = true;
2021-10-03 16:19:37 +02:00
kernelModules = [ "kvm-intel" ];
binfmt.emulatedSystems = [ "armv6l-linux" "armv7l-linux" "aarch64-linux" ];
};
nix = {
buildCores = 40;
maxJobs = 4;
package = lib.mkForce pkgs.nixUnstable;
2021-10-03 16:19:37 +02:00
trustedUsers = [ "client" ];
extraOptions = ''
builders-use-substitutes = true
'';
};
# time.timeZone = "Europe/Amsterdam";
environment.systemPackages = with pkgs; [
wget
vim
git
];
services.openssh.enable = true;
services.openssh.permitRootLogin = lib.mkForce "yes";
2021-10-03 16:19:37 +02:00
# This value determines the NixOS release from which the default
# settings for stateful data, like file locations and database versions
# on your system were taken. Its perfectly fine and recommended to leave
# this value at the release version of the first install of this system.
# Before changing this value read the documentation for this option
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
system.stateVersion = "20.09"; # Did you read the comment?
}