fix: aqua - networking

This commit is contained in:
Ryan Yin
2024-07-30 13:48:38 +08:00
parent 6670c5bd7d
commit e86d7a1020
3 changed files with 15 additions and 11 deletions
+13 -6
View File
@@ -1,4 +1,8 @@
{myvars, ...}: {
mylib,
myvars,
...
}:
############################################################# #############################################################
# #
# Aquamarine - A NixOS VM running on Proxmox/KubeVirt # Aquamarine - A NixOS VM running on Proxmox/KubeVirt
@@ -7,25 +11,28 @@
let let
hostName = "aquamarine"; # Define your hostname. hostName = "aquamarine"; # Define your hostname.
in { in {
imports = [ imports = mylib.scanPaths ./.;
];
# supported file systems, so we can mount any removable disks with these filesystems # supported file systems, so we can mount any removable disks with these filesystems
boot.supportedFilesystems = [ boot.supportedFilesystems = [
"ext4" "ext4"
"btrfs" "btrfs"
"xfs" "xfs"
#"zfs"
"ntfs"
"fat" "fat"
"vfat" "vfat"
"exfat" "exfat"
]; ];
# boot.kernelModules = ["kvm-amd"]; boot.kernelModules = ["kvm-amd"];
# boot.extraModprobeConfig = "options kvm_amd nested=1"; # for amd cpu boot.extraModprobeConfig = "options kvm_amd nested=1"; # for amd cpu
networking = { networking = {
inherit hostName; inherit hostName;
inherit (myvars.networking) nameservers; inherit (myvars.networking) defaultGateway nameservers;
inherit (myvars.networking.hostsInterface.${hostName}) interfaces;
networkmanager.enable = false;
}; };
# This value determines the NixOS release from which the default # This value determines the NixOS release from which the default
@@ -19,11 +19,8 @@
]; ];
config = { config = {
# backup only once a week inside all virtual machines # disable backups in the VM
services.btrbk.instances.btrbk = { services.btrbk.instances = lib.mkFOrce {};
onCalendar = lib.mkForce "Wed *-*-* 5:25:20";
settings.snapshot_preserve = lib.mkForce "7d";
};
fileSystems."/" = { fileSystems."/" = {
device = "/dev/disk/by-label/nixos"; device = "/dev/disk/by-label/nixos";