refactor(nixos): move networking config to its own module

This commit is contained in:
Mohammad Rafiq 2025-06-16 18:40:02 +08:00
parent b7e9cdf51d
commit 5f71bc8925
No known key found for this signature in database
3 changed files with 23 additions and 28 deletions

View file

@ -10,7 +10,6 @@ in
imports = [
./nvidia.nix
./audio.nix
./networking.nix
];
options.hardware = {

View file

@ -1,27 +0,0 @@
{ config, lib, ... }:
let
inherit (lib) singleton;
in
{
config = {
networking = {
enableIPv6 = false;
useDHCP = lib.mkDefault true;
hostName = config.system.hostname;
networkmanager.enable = true;
};
services.openssh = {
enable = true;
settings = {
PrintMotd = true;
};
};
services.tailscale = {
enable = true;
authKeyFile = config.sops.secrets."keys/tailscale".path;
};
persistDirs = singleton "/var/lib/tailscale";
};
}