dotfiles/host/hummelberg-old/networking.nix

26 lines
721 B
Nix

{ config, pkgs, ... }:
{
networking = {
networkmanager.enable = true;
useDHCP = false;
#wireless.enable = true; # Enables wireless support via wpa_supplicant.
hostName = "hummelberg";
};
# Configure network proxy if necessary
# networking.proxy.default = "http://user:password@proxy:port/";
# networking.proxy.noProxy = "127.0.0.1,localhost,internal.domain";
networking.wireguard.enable = true;
networking.wireguard.interfaces = let
meta = import ../../meta;
vnetworks = meta.network.virtual;
vnetworkName = "mgmt";
in {
"wg-${vnetworkName}" =
pkgs.lib.qois.wireguard.makeInterface config.networking.hostName
vnetworkName vnetworks.${vnetworkName};
};
}