nextcloud: init
This commit is contained in:
parent
56ab27d661
commit
35e93ce43b
8 changed files with 266 additions and 0 deletions
51
hosts/dishwasher/mcvm-network.nix
Normal file
51
hosts/dishwasher/mcvm-network.nix
Normal file
|
@ -0,0 +1,51 @@
|
|||
{ config, pkgs, ... }: {
|
||||
systemd.network = {
|
||||
netdevs."microvm-bridge".netdevConfig = {
|
||||
Kind = "bridge";
|
||||
Name = "microvm-bridge";
|
||||
};
|
||||
|
||||
networks."0-microvm-bridge" = {
|
||||
matchConfig.Name = "microvm-bridge";
|
||||
networkConfig = {
|
||||
DHCPServer = false;
|
||||
IPv6SendRA = true;
|
||||
};
|
||||
addresses = [ {
|
||||
addressConfig.Address = "10.99.99.1/24";
|
||||
} {
|
||||
addressConfig.Address = "fd12:3456:789a::1/64";
|
||||
} ];
|
||||
ipv6Prefixes = [ {
|
||||
ipv6PrefixConfig.Prefix = "fd12:3456:789a::/64";
|
||||
} ];
|
||||
# networkConfig = {
|
||||
# Address = "10.99.99.1/24";
|
||||
# IPForward = "ipv4";
|
||||
# };
|
||||
# routes = [{
|
||||
# routeConfig = {
|
||||
# GatewayOnLink = true;
|
||||
# };}];
|
||||
# IPForward = "ipv4";
|
||||
# DHCPServer = true;
|
||||
# IPv6SendRA = true;
|
||||
# addresses = [{
|
||||
# addressConfig.Address = "10.99.99.1/24";
|
||||
# }];
|
||||
};
|
||||
|
||||
networks."1-microvm-bridge" = {
|
||||
matchConfig.Name = "vm-*";
|
||||
networkConfig.Bridge = "microvm-bridge";
|
||||
};
|
||||
};
|
||||
|
||||
networking.nat = {
|
||||
enable = true;
|
||||
enableIPv6 = true;
|
||||
externalInterface = "enp1s0";
|
||||
internalInterfaces = [ "microvm-bridge" ];
|
||||
};
|
||||
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue