hardcoded networking setup for nix run vm 101

Signed-off-by: Kiara Grouwstra <kiara@procolix.eu>
This commit is contained in:
Kiara Grouwstra 2025-09-26 21:26:12 +02:00
parent 9118e9ab2d
commit 31297aacc6
Signed by: kiara
SSH key fingerprint: SHA256:COspvLoLJ5WC5rFb9ZDe5urVCkK4LJZOsjfF4duRJFU
2 changed files with 32 additions and 1 deletions

View file

@ -143,6 +143,36 @@ let
system.stateVersion = "25.05"; system.stateVersion = "25.05";
services.qemuGuest.enable = true; services.qemuGuest.enable = true;
networking = {
firewall.enable = false;
usePredictableInterfaceNames = false;
interfaces.eth0.ipv4.addresses = [
{
address = "95.215.187.101";
prefixLength = 24;
}
];
interfaces.eth0.ipv6.addresses = [
{
address = "2a00:51c0:13:1305::101";
prefixLength = 64;
}
];
defaultGateway = {
address = "95.215.187.1";
interface = "eth0";
};
defaultGateway6 = {
address = "2a00:51c0:13:1305::1";
interface = "eth0";
};
nameservers = [
"95.215.185.6"
"95.215.185.7"
"2a00:51c0::5fd7:b906"
"2a00:51c0::5fd7:b907"
];
};
users.users = environment.config.resources."operator-environment".login-shell.apply { users.users = environment.config.resources."operator-environment".login-shell.apply {
resources = lib.filterAttrs (_name: value: value ? login-shell) ( resources = lib.filterAttrs (_name: value: value ? login-shell) (

View file

@ -148,7 +148,8 @@ resource "proxmox_virtual_environment_vm" "nix_vm" {
network_device { network_device {
model = "virtio" model = "virtio"
bridge = "vnet1306" bridge = "ovsbr0"
vlan_id = 1305
} }
operating_system { operating_system {