2020-05-12 22:54:39 +02:00
|
|
|
{ lib, pkgs, ... }:
|
|
|
|
let
|
|
|
|
|
|
|
|
interface = "eno1";
|
|
|
|
ipAddress = "10.1.0.1";
|
|
|
|
prefixLength = 24;
|
|
|
|
|
2021-11-01 09:20:42 +01:00
|
|
|
in
|
|
|
|
{
|
2020-05-12 22:54:39 +02:00
|
|
|
|
|
|
|
networking.extraHosts = ''
|
|
|
|
10.1.0.1 workout.lan
|
|
|
|
10.1.0.2 pepe.lan
|
|
|
|
'';
|
|
|
|
|
|
|
|
# todo only open needed ports
|
|
|
|
networking.firewall.trustedInterfaces = [ interface ];
|
|
|
|
|
|
|
|
networking.networkmanager.unmanaged = [ interface ];
|
|
|
|
networking.dhcpcd.denyInterfaces = [ interface ];
|
|
|
|
|
|
|
|
networking.interfaces."${interface}".ipv4.addresses = [{
|
|
|
|
address = ipAddress;
|
|
|
|
prefixLength = prefixLength;
|
|
|
|
}];
|
|
|
|
|
|
|
|
}
|