many changes and more modularizing

This commit is contained in:
2024-12-12 22:30:24 +01:00
parent df50e70f3e
commit c96c24f864
109 changed files with 20900 additions and 278 deletions

View File

@@ -6,6 +6,7 @@ let
url = "https://github.com/nixos/nixpkgs/";
rev = "41dea55321e5a999b17033296ac05fe8a8b5a257";
}) {};
networkPrefix = config.networkPrefix;
in
{
users.users.hass = {
@@ -35,8 +36,8 @@ in
ephemeral = false;
privateNetwork = true;
hostBridge = "server";
hostAddress = "10.42.97.1";
localAddress = "10.42.97.20/24";
hostAddress = "${networkPrefix}.97.1";
localAddress = "${networkPrefix}.97.20/24";
extraFlags = [
"--capability=CAP_NET_ADMIN"
"--capability=CAP_MKNOD"
@@ -74,7 +75,9 @@ in
};
};
config = { lib, config, pkgs, ... }: {
networkPrefix = networkPrefix;
imports = [
../network-prefix.nix
./3dprinter.nix
./ac.nix
# ./aeg.nix
@@ -103,11 +106,11 @@ in
hostName = "home-assistant";
useHostResolvConf = false;
defaultGateway = {
address = "10.42.96.1";
address = "${networkPrefix}.96.1";
interface = "eth0";
};
firewall.enable = false;
nameservers = [ "10.42.97.1" ];
nameservers = [ "${networkPrefix}.97.1" ];
};
environment.systemPackages = [