Cleanup more networking

This commit is contained in:
Dave Gallant
2021-05-05 22:46:37 -04:00
parent 1d375c8711
commit 4e8c0ac373
3 changed files with 15 additions and 15 deletions

View File

@@ -7,13 +7,15 @@
boot.loader.systemd-boot.enable = true; boot.loader.systemd-boot.enable = true;
boot.loader.efi.canTouchEfiVariables = true; boot.loader.efi.canTouchEfiVariables = true;
networking.hostName = "hephaestus"; # Define your hostname. networking.hostName = "hephaestus";
# The global useDHCP flag is deprecated, therefore explicitly set to false here. networking = {
# Per-interface useDHCP will be mandatory in the future, so this generated config interfaces.enp34s0 = { useDHCP = true; };
# replicates the default behaviour. defaultGateway = {
networking.useDHCP = false; address = "192.168.0.1";
networking.interfaces.enp34s0.useDHCP = true; interface = "enp34s0";
};
};
# Enable the OpenSSH server. # Enable the OpenSSH server.
services.sshd.enable = true; services.sshd.enable = true;

View File

@@ -7,12 +7,8 @@
boot.loader.systemd-boot.enable = true; boot.loader.systemd-boot.enable = true;
boot.loader.efi.canTouchEfiVariables = true; boot.loader.efi.canTouchEfiVariables = true;
networking.hostName = "hermes"; # Define your hostname. networking.hostName = "hermes";
# The global useDHCP flag is deprecated, therefore explicitly set to false here.
# Per-interface useDHCP will be mandatory in the future, so this generated config
# replicates the default behaviour.
networking.useDHCP = false;
networking.interfaces.wlp61s0.useDHCP = true; networking.interfaces.wlp61s0.useDHCP = true;
} }

View File

@@ -3,9 +3,11 @@
{ {
services.tailscale.enable = true; services.tailscale.enable = true;
networking.firewall = { networking = {
allowPing = false; firewall = {
enable = true; allowPing = false;
trustedInterfaces = [ "tailscale0" ]; enable = true;
trustedInterfaces = [ "tailscale0" ];
};
}; };
} }