1
0
forked from extern/nix-config
donovanglover-nix-config/host/mullvad/default.nix

32 lines
557 B
Nix
Raw Normal View History

2023-05-19 08:54:35 +02:00
{ pkgs, ... }:
2023-05-17 15:23:38 +02:00
{
2023-05-19 08:54:35 +02:00
environment.systemPackages = [ pkgs.mullvad-vpn ];
2023-05-17 15:23:38 +02:00
services.mullvad-vpn = {
enable = true;
enableExcludeWrapper = false;
};
networking.firewall.allowedTCPPorts = [ 11918 ];
2023-05-17 15:23:38 +02:00
networking = {
nat = {
enable = true;
internalInterfaces = [ "ve-+" ];
externalInterface = "wg-mullvad";
forwardPorts = [
{
destination = "192.168.100.11:80";
sourcePort = 11918;
}
];
2023-05-17 15:23:38 +02:00
};
networkmanager = {
unmanaged = [ "interface-name:ve-*" ];
};
};
}