Add Incus to the server services, put Kitty on its own router for an extra public IP
This commit is contained in:
parent
9c2bf2a898
commit
95140d5a0e
7 changed files with 45 additions and 6 deletions
|
@ -5,6 +5,8 @@
|
||||||
./disko
|
./disko
|
||||||
./filesystems
|
./filesystems
|
||||||
./hardware
|
./hardware
|
||||||
|
./network
|
||||||
|
./services
|
||||||
];
|
];
|
||||||
|
|
||||||
system = {
|
system = {
|
||||||
|
@ -16,8 +18,4 @@
|
||||||
};
|
};
|
||||||
|
|
||||||
deployment.targetHost = "53f:dc2d:80c9:3ca2:4b15:ef4d:38a0:c868";
|
deployment.targetHost = "53f:dc2d:80c9:3ca2:4b15:ef4d:38a0:c868";
|
||||||
|
|
||||||
networking.hostId = "8745e22e";
|
|
||||||
|
|
||||||
services.nfs.server.enable = true;
|
|
||||||
}
|
}
|
||||||
|
|
14
hosts/kitty/network/default.nix
Normal file
14
hosts/kitty/network/default.nix
Normal file
|
@ -0,0 +1,14 @@
|
||||||
|
{ ... }:
|
||||||
|
{
|
||||||
|
networking = {
|
||||||
|
interfaces."eno1".ipv4.addresses = [{
|
||||||
|
address = "11.2.0.1";
|
||||||
|
prefixLength = 8;
|
||||||
|
}];
|
||||||
|
defaultGateway = {
|
||||||
|
address = "11.1.0.1";
|
||||||
|
interface = "eno1";
|
||||||
|
};
|
||||||
|
hostId = "8745e22e";
|
||||||
|
};
|
||||||
|
}
|
9
hosts/kitty/services/default.nix
Normal file
9
hosts/kitty/services/default.nix
Normal file
|
@ -0,0 +1,9 @@
|
||||||
|
{ ... }:
|
||||||
|
{
|
||||||
|
services = {
|
||||||
|
nfs.server.enable = true;
|
||||||
|
nginx.enable = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
virtualisation.incus.enable = true;
|
||||||
|
}
|
|
@ -2,11 +2,11 @@
|
||||||
{
|
{
|
||||||
networking = {
|
networking = {
|
||||||
interfaces."enp0s31f6".ipv4.addresses = [{
|
interfaces."enp0s31f6".ipv4.addresses = [{
|
||||||
address = "10.2.0.1";
|
address = "11.2.0.1";
|
||||||
prefixLength = 8;
|
prefixLength = 8;
|
||||||
}];
|
}];
|
||||||
defaultGateway = {
|
defaultGateway = {
|
||||||
address = "10.1.0.1";
|
address = "11.1.0.1";
|
||||||
interface = "enp0s31f6";
|
interface = "enp0s31f6";
|
||||||
};
|
};
|
||||||
hostId = "38ba3f57";
|
hostId = "38ba3f57";
|
||||||
|
|
|
@ -4,6 +4,7 @@
|
||||||
./cfdyndns
|
./cfdyndns
|
||||||
./forgejo
|
./forgejo
|
||||||
./icecast
|
./icecast
|
||||||
|
./incus
|
||||||
./jellyfin
|
./jellyfin
|
||||||
./mailserver
|
./mailserver
|
||||||
./mastodon
|
./mastodon
|
||||||
|
|
16
modules/system/services/server/incus/default.nix
Normal file
16
modules/system/services/server/incus/default.nix
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
{ config, lib, pkgs, ... }:
|
||||||
|
{
|
||||||
|
config = lib.mkIf config.virtualisation.incus.enable {
|
||||||
|
networking.firewall.interfaces.incusbr0 = let
|
||||||
|
ports = [
|
||||||
|
53
|
||||||
|
67
|
||||||
|
];
|
||||||
|
in {
|
||||||
|
allowedTCPPorts = ports;
|
||||||
|
allowedUDPPorts = ports;
|
||||||
|
};
|
||||||
|
|
||||||
|
environment.persistence."/persist".directories = [ "/var/lib/incus" ];
|
||||||
|
};
|
||||||
|
}
|
|
@ -36,6 +36,7 @@
|
||||||
"libvirtd"
|
"libvirtd"
|
||||||
"qemu-libvirtd"
|
"qemu-libvirtd"
|
||||||
|
|
||||||
|
"incus-admin"
|
||||||
"minecraft"
|
"minecraft"
|
||||||
"nfsShare"
|
"nfsShare"
|
||||||
"nginx"
|
"nginx"
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue