mirror of
https://github.com/ryan4yin/nix-config.git
synced 2026-04-26 18:58:28 +02:00
feat: migrate all nixos services from idols to 12kingdoms
This commit is contained in:
19
hosts/12kingdoms-suzu/microvm/mitsuha/networking.nix
Normal file
19
hosts/12kingdoms-suzu/microvm/mitsuha/networking.nix
Normal file
@@ -0,0 +1,19 @@
|
||||
{myvars, ...}: let
|
||||
hostName = "mitsuha";
|
||||
inherit (myvars.networking) mainGateway nameservers;
|
||||
inherit (myvars.networking.hostsAddr.${hostName}) ipv4;
|
||||
|
||||
ipv4WithMask = "${ipv4}/24";
|
||||
in {
|
||||
systemd.network.enable = true;
|
||||
|
||||
systemd.network.networks."20-lan" = {
|
||||
matchConfig.Type = "ether";
|
||||
networkConfig = {
|
||||
Address = [ipv4WithMask];
|
||||
Gateway = mainGateway;
|
||||
DNS = nameservers;
|
||||
DHCP = "no";
|
||||
};
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user