{ lib, config, pkgs, ... }: let hostname = "lambda"; host-internal-ip = "10.0.0.3"; host-storage-ip = "10.0.10.1"; inherit (lib.strings) concatStringsSep; in { boot.kernelModules = [ "kvm-amd" ]; boot.loader.grub.enable = true; boot.loader.grub.version = 2; boot.loader.grub.device = "/dev/disk/by-label/nixos-root"; hardware.bluetooth.enable = false; imports = [ ../defaults.nix ../hardware-configuration.nix ]; fudo.common = { profile = "server"; site = "seattle"; }; fudo.slynk = { enable = true; }; networking = { hostName = hostname; nameservers = [ host-internal-ip ]; # Create a bridge for VMs to use macvlans = { extif0 = { interface = "enp3s0f1"; mode = "bridge"; }; storageif0 = { interface = "enp4s0f1"; mode = "bridge"; }; }; interfaces = { enp3s0f0.useDHCP = false; enp3s0f1.useDHCP = false; enp4s0f0.useDHCP = false; enp4s0f1.useDHCP = false; extif0 = { useDHCP = false; macAddress = "02:50:f6:52:9f:9d"; ipv4.addresses = [{ address = host-internal-ip; prefixLength = 22; } # { # address = "10.0.10.2"; # prefixLength = 24; # } ]; }; storageif0 = { useDHCP = false; macAddress = "02:65:d7:00:7d:1b"; ipv4.addresses = [{ address = host-storage-ip; prefixLength = 24; }]; }; }; }; fudo.ipfs = { enable = true; users = [ "niten" ]; api-address = "/ip4/${host-internal-ip}/tcp/5001"; }; }