1
0
nixfiles/hosts/zinc/configuration.nix

56 lines
1.2 KiB
Nix
Raw Normal View History

2023-09-20 20:35:35 +02:00
{ config, pkgs, lib, ... }:
{
imports =
[
./hardware-configuration.nix
];
# Use the systemd-boot EFI boot loader.
boot.loader.systemd-boot.enable = true;
boot.loader.efi.canTouchEfiVariables = true;
boot.loader.timeout = 0;
boot.initrd.luks = {
devices.lvm = {
device = "/dev/disk/by-uuid/43275d9a-8fe8-4631-bf9c-a95d692b534f";
bypassWorkqueues = true;
};
};
boot.initrd.network.enable = true;
boot.initrd.network.ssh = {
enable = true;
port = 1022;
#shell = "/bin/cryptsetup-askpass";
2023-09-20 20:35:35 +02:00
authorizedKeys = config.users.users.clerie.openssh.authorizedKeys.keys;
hostKeys = [
"/var/src/secrets/initrd/ssh_host_ed25519_key"
];
};
2023-09-22 20:55:43 +02:00
boot.initrd.kernelModules = [
"igc" # integrated rj45 network interface
"cdc_ether" # 5G modem via usb
];
2023-09-20 20:35:35 +02:00
boot.kernelParams = [ "ip=dhcp" ];
boot.initrd.network.wireguard = {
enable = true;
ipv6s = [ "2a01:4f8:c0c:15f1::8110/128" ];
ipv4s = [ "10.20.30.110/32" ];
privateKeyFile = "/var/src/secrets/wireguard/wg-initrd";
};
2023-09-20 20:35:35 +02:00
networking.hostName = "zinc";
2023-09-20 21:01:40 +02:00
services.wg-clerie = {
enable = true;
ipv6s = [ "2a01:4f8:c0c:15f1::8109/128" ];
ipv4s = [ "10.20.30.109/32" ];
};
2023-09-20 20:35:35 +02:00
system.stateVersion = "23.05";
}