70 lines
2.5 KiB
Nix
70 lines
2.5 KiB
Nix
{ pkgs, inputs, config, ... }:
|
|
{
|
|
imports = [
|
|
(import ../Common/default.nix { inherit inputs pkgs config; })
|
|
(import ../Common/nvidia.nix { inherit inputs pkgs config; })
|
|
(import ../Common/desktop.nix { inherit inputs pkgs config; })
|
|
(import ../Common/nfs.nix { inherit inputs pkgs config; })
|
|
];
|
|
hardware.graphics.extraPackages = [
|
|
pkgs.intel-compute-runtime
|
|
pkgs.intel-media-driver
|
|
];
|
|
|
|
zramSwap.enable = true;
|
|
services.logind.extraConfig = ''HandlePowerKey=ignore'';
|
|
# services.ollama = {
|
|
# enable = true;
|
|
# };
|
|
programs.nix-ld.enable = true;
|
|
|
|
virtualisation.libvirtd.enable = true;
|
|
virtualisation.libvirtd.qemu.ovmf.enable = true;
|
|
virtualisation.spiceUSBRedirection.enable = true;
|
|
programs.virt-manager.enable = true;
|
|
users.users.user.extraGroups = [ "libvirtd" ];
|
|
|
|
networking.wg-quick.interfaces = {
|
|
Tunnel = {
|
|
address = [ "10.0.0.5/24" "2a02:a03f:83ad:2101::5/128" ];
|
|
privateKeyFile = "/home/user/.secrets/Wireguard/Aloria.key";
|
|
listenPort = 51820;
|
|
autostart = true;
|
|
postUp = "resolvectl dns Tunnel 10.0.0.1; resolvectl domain Tunnel ~thomasave.be;";
|
|
dns = ["10.0.0.1"];
|
|
peers = [{
|
|
publicKey = "/9ppjm3yeD0duDvxrqgcHscHmftXko+0s2RbivNEy2c=";
|
|
allowedIPs = [ "0.0.0.0/0" "::/0" ];
|
|
endpoint = "h.thomasave.be:13231";
|
|
persistentKeepalive = 25;
|
|
}];
|
|
};
|
|
OPNsense = {
|
|
address = [ "10.0.0.5/24" "2a02:a03f:83ad:2101::5/128" ];
|
|
privateKeyFile = "/home/user/.secrets/Wireguard/Aloria.key";
|
|
listenPort = 51820;
|
|
autostart = false;
|
|
postUp = "resolvectl dns OPNsense 10.0.0.1; resolvectl domain OPNsense ~thomasave.be;";
|
|
dns = ["10.0.0.1"];
|
|
peers = [{
|
|
publicKey = "/9ppjm3yeD0duDvxrqgcHscHmftXko+0s2RbivNEy2c=";
|
|
allowedIPs = [ "10.0.0.1/8" "192.168.1.2/32" ];
|
|
endpoint = "h.thomasave.be:13231";
|
|
persistentKeepalive = 25;
|
|
}];
|
|
};
|
|
};
|
|
fileSystems."/home/server".device = pkgs.lib.mkForce "10.0.0.1:/home/server";
|
|
|
|
services.upower.enable = true;
|
|
networking.wireless.iwd.enable = true;
|
|
networking.wireless.iwd.settings = {
|
|
IPv6 = {
|
|
Enabled = true;
|
|
};
|
|
Settings = {
|
|
AutoConnect = true;
|
|
};
|
|
};
|
|
}
|