nixos-config/config/host-config/cashew.nix

33 lines
588 B
Nix

{ config, lib, pkgs, ... }:
with lib;
let
hostname = config.instance.hostname;
host-ipv4 = "208.81.4.82";
site-name = config.fudo.hosts.${hostname}.site;
site = config.fudo.sites.${site-name};
local-packages = with pkgs; [
bind
];
in {
config = {
networking = {
defaultGateway = {
address = site.gateway-v4;
interface = "extif0";
};
interfaces.extif0 = {
ipv4.addresses = [{
address = host-ipv4;
prefixLength = 29;
}];
};
};
environment.systemPackages = local-packages;
};
}