diff --git a/README.md b/README.md index 8b002045..a3b2850d 100644 --- a/README.md +++ b/README.md @@ -24,8 +24,8 @@ This repository is home to the nix code that builds my systems: 1. NixOS Desktops: NixOS with home-manager, i3, hyprland, agenix, etc. 2. macOS Desktops: nix-darwin with home-manager, share the same home-manager configuration with NixOS Desktops. -3. NixOS Servers: virtual machines running on Proxmox, with various services, such as kubernetes, - homepage, prometheus, grafana, etc. +3. NixOS Servers: virtual machines running on Proxmox/KubeVirt, with various services, such as + kubernetes, homepage, prometheus, grafana, etc. See [./hosts](./hosts) for details of each host. diff --git a/hosts/12kingdoms-rakushun/homepage/config/services.yaml b/hosts/12kingdoms-rakushun/homepage/config/services.yaml index 06f76f1c..c02184d9 100644 --- a/hosts/12kingdoms-rakushun/homepage/config/services.yaml +++ b/hosts/12kingdoms-rakushun/homepage/config/services.yaml @@ -2,24 +2,31 @@ # For configuration options and examples, please see: # https://gethomepage.dev/latest/configs/services -- Proxmox VE 虚拟化集群: - - PVE-UM560: - icon: si-proxmox - href: https://192.168.5.173:8006/ - description: "CPU: R5-5625U / MEM: 32G / DISK: 512G+4T*2" - siteMonitor: https://192.168.5.173:8006/ - - - PVE-S500Plus: - icon: si-proxmox - href: https://192.168.5.174:8006/ +- KubeVirt 虚拟化集群: + - KubeVirt-Shoryu: + icon: si-kubevirt description: "CPU: R7-5825U / MEM: 64G / DISK: 1T" - siteMonitor: https://192.168.5.174:8006/ - - - PVE-GTR5: - icon: si-proxmox - href: https://192.168.5.172:8006/ + href: http://grafana.writefor.fun/d/rYdddlPWk/node-exporter-full?orgId=1&var-node=192.168.5.181:9100 + siteMonitor: http://grafana.writefor.fun/d/rYdddlPWk/node-exporter-full?orgId=1&var-node=192.168.5.181:9100 + - KubeVirt-Shushou: + icon: si-kubevirt description: "CPU: R9-5900HX / MEM: 64G / DISK: 1T" - siteMonitor: https://192.168.5.172:8006/ + href: http://grafana.writefor.fun/d/rYdddlPWk/node-exporter-full?orgId=1&var-node=192.168.5.182:9100 + siteMonitor: http://grafana.writefor.fun/d/rYdddlPWk/node-exporter-full?orgId=1&var-node=192.168.5.182:9100 + - KubeVirt-Youko: + icon: si-kubevirt + description: "CPU: R5-5625U / MEM: 32G / DISK: 512G+4T*2" + href: http://grafana.writefor.fun/d/rYdddlPWk/node-exporter-full?orgId=1&var-node=192.168.5.183:9100 + siteMonitor: http://grafana.writefor.fun/d/rYdddlPWk/node-exporter-full?orgId=1&var-node=192.168.5.183:9100 + - LongHorn-Storage: + icon: si-longhorn + href: http://longhorn.writefor.fun/ + - Victoria-Metrics: + icon: si-victoriametrics + href: http://vm.writefor.fun/ + - KubeVirt-Grafana: + icon: si-grafana + href: http://k8s-grafana.writefor.fun/ - Homelab Monitoring: - Grafana: diff --git a/hosts/12kingdoms-rakushun/homepage/config/settings.yaml b/hosts/12kingdoms-rakushun/homepage/config/settings.yaml index 54e8940a..33870a3d 100644 --- a/hosts/12kingdoms-rakushun/homepage/config/settings.yaml +++ b/hosts/12kingdoms-rakushun/homepage/config/settings.yaml @@ -40,8 +40,8 @@ useEqualHeights: true # Groups and its layout # Groups Name should match the name defined in your services.yaml or widgets.yaml layout: - Proxmox VE 虚拟化集群: - icon: si-proxmox + KubeVirt 虚拟化集群: + icon: si-kubevirt tab: First Group A: diff --git a/hosts/12kingdoms-rakushun/restic.nix b/hosts/12kingdoms-rakushun/restic.nix index c300604f..77197875 100644 --- a/hosts/12kingdoms-rakushun/restic.nix +++ b/hosts/12kingdoms-rakushun/restic.nix @@ -8,7 +8,7 @@ in { homelab-backup = { inherit passwordFile; initialize = true; # Initialize the repository if it doesn't exist. - repository = "rclone:smb-downloads:/Downloads/proxmox-backup/"; # backup to a rclone remote + repository = "rclone:smb-downloads:/Downloads/kubevirt-backup/"; # backup to a rclone remote # rclone related # rcloneOptions = { @@ -34,20 +34,16 @@ in { # A script that must run before starting the backup process. backupPrepareCommand = '' ${pkgs.nushell}/bin/nu -c ' - let pve_nodes = [ - # proxmox cluster's nodes - "um560" - "gtr5" - "s500plus" - - # others - "kana" + let kubevirt_nodes = [ + "kubevirt-shoryu" + "kubevirt-shushou" + "kubevirt-youko" ] - pve_nodes | each {|it| + kubevirt_nodes | each {|it| rsync -avz \ -e "ssh -i ${sshKeyPath}" \ - $"($it):/var/lib/vz" $"/tmp/restic-backup-temp/($it)" + $"($it):/perissitent/" $"/tmp/restic-backup-temp/($it)" } ' ''; diff --git a/hosts/idols-aquamarine/default.nix b/hosts/idols-aquamarine/default.nix index b39993d6..9ee46cc8 100644 --- a/hosts/idols-aquamarine/default.nix +++ b/hosts/idols-aquamarine/default.nix @@ -1,7 +1,7 @@ {myvars, ...}: ############################################################# # -# Aquamarine - A NixOS VM running on Proxmox +# Aquamarine - A NixOS VM running on Proxmox/KubeVirt # ############################################################# let diff --git a/hosts/idols-kana/default.nix b/hosts/idols-kana/default.nix index 9a16acb0..c5579341 100644 --- a/hosts/idols-kana/default.nix +++ b/hosts/idols-kana/default.nix @@ -5,7 +5,7 @@ }: ############################################################# # -# Kana - a NixOS VM running on Proxmox +# Kana - a NixOS VM running on Proxmox/KubeVirt # ############################################################# let diff --git a/hosts/idols-ruby/default.nix b/hosts/idols-ruby/default.nix index bb107586..dccec52a 100644 --- a/hosts/idols-ruby/default.nix +++ b/hosts/idols-ruby/default.nix @@ -5,7 +5,7 @@ }: ############################################################# # -# Ruby - a NixOS VM running on Proxmox +# Ruby - a NixOS VM running on Proxmox/KubeVirt # ############################################################# let diff --git a/hosts/k8s/k3s-prod-1-master-1/default.nix b/hosts/k8s/k3s-prod-1-master-1/default.nix index 82b1ea88..4863354f 100644 --- a/hosts/k8s/k3s-prod-1-master-1/default.nix +++ b/hosts/k8s/k3s-prod-1-master-1/default.nix @@ -7,7 +7,7 @@ }: let hostName = "k3s-prod-1-master-1"; # Define your hostname. - coreModule = mylib.genKubeVirtCoreModule { + coreModule = mylib.genKubeVirtGuestModule { inherit pkgs hostName; inherit (myvars) networking; }; diff --git a/hosts/k8s/k3s-prod-1-master-2/default.nix b/hosts/k8s/k3s-prod-1-master-2/default.nix index 2133c9c0..86100af1 100644 --- a/hosts/k8s/k3s-prod-1-master-2/default.nix +++ b/hosts/k8s/k3s-prod-1-master-2/default.nix @@ -7,7 +7,7 @@ }: let hostName = "k3s-prod-1-master-2"; # define your hostname. - coreModule = mylib.genKubeVirtCoreModule { + coreModule = mylib.genKubeVirtGuestModule { inherit pkgs hostName; inherit (myvars) networking; }; diff --git a/hosts/k8s/k3s-prod-1-master-3/default.nix b/hosts/k8s/k3s-prod-1-master-3/default.nix index b5ff12a8..850f1867 100644 --- a/hosts/k8s/k3s-prod-1-master-3/default.nix +++ b/hosts/k8s/k3s-prod-1-master-3/default.nix @@ -7,7 +7,7 @@ }: let hostName = "k3s-prod-1-master-3"; # define your hostname. - coreModule = mylib.genKubeVirtCoreModule { + coreModule = mylib.genKubeVirtGuestModule { inherit pkgs hostName; inherit (myvars) networking; }; diff --git a/hosts/k8s/k3s-prod-1-worker-1/default.nix b/hosts/k8s/k3s-prod-1-worker-1/default.nix index ee076146..85813fbe 100644 --- a/hosts/k8s/k3s-prod-1-worker-1/default.nix +++ b/hosts/k8s/k3s-prod-1-worker-1/default.nix @@ -7,7 +7,7 @@ }: let hostName = "k3s-prod-1-worker-1"; # define your hostname. - coreModule = mylib.genKubeVirtCoreModule { + coreModule = mylib.genKubeVirtGuestModule { inherit pkgs hostName; inherit (myvars) networking; }; diff --git a/hosts/k8s/k3s-prod-1-worker-2/default.nix b/hosts/k8s/k3s-prod-1-worker-2/default.nix index f534589e..5952204b 100644 --- a/hosts/k8s/k3s-prod-1-worker-2/default.nix +++ b/hosts/k8s/k3s-prod-1-worker-2/default.nix @@ -7,7 +7,7 @@ }: let hostName = "k3s-prod-1-worker-2"; # define your hostname. - coreModule = mylib.genKubeVirtCoreModule { + coreModule = mylib.genKubeVirtGuestModule { inherit pkgs hostName; inherit (myvars) networking; }; diff --git a/hosts/k8s/k3s-prod-1-worker-3/default.nix b/hosts/k8s/k3s-prod-1-worker-3/default.nix index 0acec9e5..59e839bd 100644 --- a/hosts/k8s/k3s-prod-1-worker-3/default.nix +++ b/hosts/k8s/k3s-prod-1-worker-3/default.nix @@ -7,7 +7,7 @@ }: let hostName = "k3s-prod-1-worker-3"; # define your hostname. - coreModule = mylib.genKubeVirtCoreModule { + coreModule = mylib.genKubeVirtGuestModule { inherit pkgs hostName; inherit (myvars) networking; }; diff --git a/hosts/k8s/k3s-test-1-master-1/default.nix b/hosts/k8s/k3s-test-1-master-1/default.nix index f635685a..b6efa033 100644 --- a/hosts/k8s/k3s-test-1-master-1/default.nix +++ b/hosts/k8s/k3s-test-1-master-1/default.nix @@ -7,7 +7,7 @@ }: let hostName = "k3s-test-1-master-1"; # Define your hostname. - coreModule = mylib.genKubeVirtCoreModule { + coreModule = mylib.genKubeVirtGuestModule { inherit pkgs hostName; inherit (myvars) networking; }; diff --git a/hosts/k8s/k3s-test-1-master-2/default.nix b/hosts/k8s/k3s-test-1-master-2/default.nix index 55746860..57c96e21 100644 --- a/hosts/k8s/k3s-test-1-master-2/default.nix +++ b/hosts/k8s/k3s-test-1-master-2/default.nix @@ -7,7 +7,7 @@ }: let hostName = "k3s-test-1-master-2"; # define your hostname. - coreModule = mylib.genKubeVirtCoreModule { + coreModule = mylib.genKubeVirtGuestModule { inherit pkgs hostName; inherit (myvars) networking; }; diff --git a/hosts/k8s/k3s-test-1-master-3/default.nix b/hosts/k8s/k3s-test-1-master-3/default.nix index ffe41f55..2d02160d 100644 --- a/hosts/k8s/k3s-test-1-master-3/default.nix +++ b/hosts/k8s/k3s-test-1-master-3/default.nix @@ -7,7 +7,7 @@ }: let hostName = "k3s-test-1-master-3"; # define your hostname. - coreModule = mylib.genKubeVirtCoreModule { + coreModule = mylib.genKubeVirtGuestModule { inherit pkgs hostName; inherit (myvars) networking; }; diff --git a/hosts/k8s/kubevirt-shoryu/default.nix b/hosts/k8s/kubevirt-shoryu/default.nix index bf8224e5..55fe587d 100644 --- a/hosts/k8s/kubevirt-shoryu/default.nix +++ b/hosts/k8s/kubevirt-shoryu/default.nix @@ -9,7 +9,7 @@ # MoreFine - S500Plus hostName = "kubevirt-shoryu"; # Define your hostname. - coreModule = mylib.genKubeVirtCoreModule { + coreModule = mylib.genKubeVirtHostModule { inherit pkgs hostName; inherit (myvars) networking; }; diff --git a/hosts/k8s/kubevirt-shushou/default.nix b/hosts/k8s/kubevirt-shushou/default.nix index 14be78ea..0d438cbc 100644 --- a/hosts/k8s/kubevirt-shushou/default.nix +++ b/hosts/k8s/kubevirt-shushou/default.nix @@ -7,9 +7,8 @@ ... }: let hostName = "kubevirt-shushou"; # Define your hostname. - k3sServerName = "kubevirt-shoryu"; - coreModule = mylib.genKubeVirtCoreModule { + coreModule = mylib.genKubeVirtHostModule { inherit pkgs hostName; inherit (myvars) networking; }; diff --git a/hosts/k8s/kubevirt-youko/default.nix b/hosts/k8s/kubevirt-youko/default.nix index 54e941d4..62e2d507 100644 --- a/hosts/k8s/kubevirt-youko/default.nix +++ b/hosts/k8s/kubevirt-youko/default.nix @@ -7,9 +7,8 @@ ... }: let hostName = "kubevirt-youko"; # Define your hostname. - k3sServerName = "kubevirt-shoryu"; - coreModule = mylib.genKubeVirtCoreModule { + coreModule = mylib.genKubeVirtHostModule { inherit pkgs hostName; inherit (myvars) networking; }; diff --git a/lib/default.nix b/lib/default.nix index 58f36d61..95663473 100644 --- a/lib/default.nix +++ b/lib/default.nix @@ -5,9 +5,10 @@ attrs = import ./attrs.nix {inherit lib;}; - genKubeVirtCoreModule = import ./genKubeVirtCoreModule.nix; genK3sServerModule = import ./genK3sServerModule.nix; genK3sAgentModule = import ./genK3sAgentModule.nix; + genKubeVirtHostModule = import ./genKubeVirtHostModule.nix; + genKubeVirtGuestModule = import ./genKubeVirtGuestModule.nix; # use path relative to the root of the project relativeToRoot = lib.path.append ../.; diff --git a/lib/genKubeVirtGuestModule.nix b/lib/genKubeVirtGuestModule.nix new file mode 100644 index 00000000..fd607922 --- /dev/null +++ b/lib/genKubeVirtGuestModule.nix @@ -0,0 +1,33 @@ +{ + pkgs, + hostName, + networking, + ... +}: let + inherit (networking.hostsAddr.${hostName}) iface; +in { + # supported file systems, so we can mount any removable disks with these filesystems + boot.supportedFilesystems = [ + "ext4" + "btrfs" + "xfs" + "fat" + "vfat" + "exfat" + ]; + + networking = { + inherit hostName; + inherit (networking) defaultGateway nameservers; + inherit (networking.hostsInterface.${hostName}) interfaces; + networkmanager.enable = false; + }; + + # This value determines the NixOS release from which the default + # settings for stateful data, like file locations and database versions + # on your system were taken. It‘s perfectly fine and recommended to leave + # this value at the release version of the first install of this system. + # Before changing this value read the documentation for this option + # (e.g. man configuration.nix or on https://nixos.org/nixos/options.html). + system.stateVersion = "23.11"; # Did you read the comment? +} diff --git a/lib/genKubeVirtCoreModule.nix b/lib/genKubeVirtHostModule.nix similarity index 100% rename from lib/genKubeVirtCoreModule.nix rename to lib/genKubeVirtHostModule.nix diff --git a/lib/nixosSystem.nix b/lib/nixosSystem.nix index a0b3038d..6203e149 100644 --- a/lib/nixosSystem.nix +++ b/lib/nixosSystem.nix @@ -17,13 +17,6 @@ in nixos-modules ++ [ nixos-generators.nixosModules.all-formats - { - # formatConfigs.iso = {config, ...}: {}; - formatConfigs.proxmox = {config, ...}: { - # custom proxmox's image name - proxmox.qemuConf.name = "${config.networking.hostName}-nixos-${config.system.nixos.label}"; - }; - } ] ++ ( lib.optionals ((lib.lists.length home-modules) > 0) diff --git a/modules/nixos/server/kubevirt-hardware-configuration.nix b/modules/nixos/server/kubevirt-hardware-configuration.nix index ab87361d..e52f46e3 100644 --- a/modules/nixos/server/kubevirt-hardware-configuration.nix +++ b/modules/nixos/server/kubevirt-hardware-configuration.nix @@ -27,7 +27,8 @@ services.qemuGuest.enable = true; services.openssh.enable = true; - services.cloud-init.enable = true; + # we configure the host via nixos itself, so we don't need the cloud-init + services.cloud-init.enable = false; systemd.services."serial-getty@ttyS0".enable = true; }; } diff --git a/modules/nixos/server/proxmox-hardware-configuration.nix b/modules/nixos/server/proxmox-hardware-configuration.nix deleted file mode 100644 index eb09fdd3..00000000 --- a/modules/nixos/server/proxmox-hardware-configuration.nix +++ /dev/null @@ -1,36 +0,0 @@ -{lib, ...}: -############################################################################## -# -# Template for Proxmox's VM, mainly based on: -# https://github.com/NixOS/nixpkgs/blob/nixos-unstable/nixos/modules/virtualisation/proxmox-image.nix -# -# the url above is used by `nixos-generator` to generate the Proxmox's VMA image file. -# -############################################################################## -{ - boot = { - # after resize the disk, it will grow partition automatically. - growPartition = true; - kernelParams = ["console=ttyS0"]; - loader.grub = { - device = "/dev/vda"; - - # we do not support EFI, so disable it. - efiSupport = false; - efiInstallAsRemovable = false; - }; - - loader.timeout = lib.mkForce 3; # wait for 3 seconds to select the boot entry - initrd.availableKernelModules = ["uas" "virtio_blk" "virtio_pci"]; - }; - - fileSystems."/" = { - device = "/dev/disk/by-label/nixos"; - autoResize = true; - fsType = "ext4"; - }; - # we do not have a /boot partition, so do not mount it. - - # it alse had qemu-guest-agent installed by default. - services.qemuGuest.enable = lib.mkDefault true; -} diff --git a/outputs/x86_64-linux/src/idols-aquamarine.nix b/outputs/x86_64-linux/src/idols-aquamarine.nix index eb1145c9..0bd12d22 100644 --- a/outputs/x86_64-linux/src/idols-aquamarine.nix +++ b/outputs/x86_64-linux/src/idols-aquamarine.nix @@ -36,6 +36,5 @@ in { colmena.${name} = mylib.colmenaSystem (systemArgs // {inherit tags ssh-user;}); - # generate proxmox image for virtual machines without desktop environment - packages.${name} = inputs.self.nixosConfigurations.${name}.config.formats.proxmox; + packages.${name} = inputs.self.nixosConfigurations.${name}.config.formats.kubevirt; } diff --git a/outputs/x86_64-linux/src/idols-kana.nix b/outputs/x86_64-linux/src/idols-kana.nix index f5d4067b..55619932 100644 --- a/outputs/x86_64-linux/src/idols-kana.nix +++ b/outputs/x86_64-linux/src/idols-kana.nix @@ -36,6 +36,5 @@ in { colmena.${name} = mylib.colmenaSystem (systemArgs // {inherit tags ssh-user;}); - # generate proxmox image for virtual machines without desktop environment - packages.${name} = inputs.self.nixosConfigurations.${name}.config.formats.proxmox; + packages.${name} = inputs.self.nixosConfigurations.${name}.config.formats.kubevirt; } diff --git a/outputs/x86_64-linux/src/idols-ruby.nix b/outputs/x86_64-linux/src/idols-ruby.nix index cc9cd98d..dfb23323 100644 --- a/outputs/x86_64-linux/src/idols-ruby.nix +++ b/outputs/x86_64-linux/src/idols-ruby.nix @@ -39,8 +39,7 @@ in { colmena.${name} = mylib.colmenaSystem (systemArgs // {inherit tags ssh-user;}); - # generate proxmox image for virtual machines without desktop environment - packages.${name} = inputs.self.nixosConfigurations.${name}.config.formats.proxmox; + packages.${name} = inputs.self.nixosConfigurations.${name}.config.formats.kubevirt; # nixos tests packages."${name}-nixos-tests" = import ../nixos-tests/idols-ruby.nix systemArgs; diff --git a/outputs/x86_64-linux/src/k3s-prod-1-master-1.nix b/outputs/x86_64-linux/src/k3s-prod-1-master-1.nix index abe62148..25c16dac 100644 --- a/outputs/x86_64-linux/src/k3s-prod-1-master-1.nix +++ b/outputs/x86_64-linux/src/k3s-prod-1-master-1.nix @@ -20,7 +20,7 @@ # common "secrets/nixos.nix" "modules/nixos/server/server.nix" - "modules/nixos/server/proxmox-hardware-configuration.nix" + "modules/nixos/server/kubevirt-hardware-configuration.nix" # host specific "hosts/k8s/${name}" ]) @@ -39,6 +39,5 @@ in { colmena.${name} = mylib.colmenaSystem (systemArgs // {inherit tags ssh-user;}); - # generate proxmox image for virtual machines without desktop environment - packages.${name} = inputs.self.nixosConfigurations.${name}.config.formats.proxmox; + packages.${name} = inputs.self.nixosConfigurations.${name}.config.formats.kubevirt; } diff --git a/outputs/x86_64-linux/src/k3s-prod-1-master-2.nix b/outputs/x86_64-linux/src/k3s-prod-1-master-2.nix index 757eae3a..42fb9778 100644 --- a/outputs/x86_64-linux/src/k3s-prod-1-master-2.nix +++ b/outputs/x86_64-linux/src/k3s-prod-1-master-2.nix @@ -20,7 +20,7 @@ # common "secrets/nixos.nix" "modules/nixos/server/server.nix" - "modules/nixos/server/proxmox-hardware-configuration.nix" + "modules/nixos/server/kubevirt-hardware-configuration.nix" # host specific "hosts/k8s/${name}" ]) @@ -36,6 +36,5 @@ in { colmena.${name} = mylib.colmenaSystem (systemArgs // {inherit tags ssh-user;}); - # generate proxmox image for virtual machines without desktop environment - packages.${name} = inputs.self.nixosConfigurations.${name}.config.formats.proxmox; + packages.${name} = inputs.self.nixosConfigurations.${name}.config.formats.kubevirt; } diff --git a/outputs/x86_64-linux/src/k3s-prod-1-master-3.nix b/outputs/x86_64-linux/src/k3s-prod-1-master-3.nix index aa375d9d..dab9e774 100644 --- a/outputs/x86_64-linux/src/k3s-prod-1-master-3.nix +++ b/outputs/x86_64-linux/src/k3s-prod-1-master-3.nix @@ -20,7 +20,7 @@ # common "secrets/nixos.nix" "modules/nixos/server/server.nix" - "modules/nixos/server/proxmox-hardware-configuration.nix" + "modules/nixos/server/kubevirt-hardware-configuration.nix" # host specific "hosts/k8s/${name}" ]) @@ -36,6 +36,5 @@ in { colmena.${name} = mylib.colmenaSystem (systemArgs // {inherit tags ssh-user;}); - # generate proxmox image for virtual machines without desktop environment - packages.${name} = inputs.self.nixosConfigurations.${name}.config.formats.proxmox; + packages.${name} = inputs.self.nixosConfigurations.${name}.config.formats.kubevirt; } diff --git a/outputs/x86_64-linux/src/k3s-prod-1-worker-1.nix b/outputs/x86_64-linux/src/k3s-prod-1-worker-1.nix index 2f7cfb3f..b225e813 100644 --- a/outputs/x86_64-linux/src/k3s-prod-1-worker-1.nix +++ b/outputs/x86_64-linux/src/k3s-prod-1-worker-1.nix @@ -20,7 +20,7 @@ # common "secrets/nixos.nix" "modules/nixos/server/server.nix" - "modules/nixos/server/proxmox-hardware-configuration.nix" + "modules/nixos/server/kubevirt-hardware-configuration.nix" # host specific "hosts/k8s/${name}" ]) @@ -36,6 +36,5 @@ in { colmena.${name} = mylib.colmenaSystem (systemArgs // {inherit tags ssh-user;}); - # generate proxmox image for virtual machines without desktop environment - packages.${name} = inputs.self.nixosConfigurations.${name}.config.formats.proxmox; + packages.${name} = inputs.self.nixosConfigurations.${name}.config.formats.kubevirt; } diff --git a/outputs/x86_64-linux/src/k3s-prod-1-worker-2.nix b/outputs/x86_64-linux/src/k3s-prod-1-worker-2.nix index b3d1c7f0..735b2c74 100644 --- a/outputs/x86_64-linux/src/k3s-prod-1-worker-2.nix +++ b/outputs/x86_64-linux/src/k3s-prod-1-worker-2.nix @@ -20,7 +20,7 @@ # common "secrets/nixos.nix" "modules/nixos/server/server.nix" - "modules/nixos/server/proxmox-hardware-configuration.nix" + "modules/nixos/server/kubevirt-hardware-configuration.nix" # host specific "hosts/k8s/${name}" ]) @@ -36,6 +36,5 @@ in { colmena.${name} = mylib.colmenaSystem (systemArgs // {inherit tags ssh-user;}); - # generate proxmox image for virtual machines without desktop environment - packages.${name} = inputs.self.nixosConfigurations.${name}.config.formats.proxmox; + packages.${name} = inputs.self.nixosConfigurations.${name}.config.formats.kubevirt; } diff --git a/outputs/x86_64-linux/src/k3s-prod-1-worker-3.nix b/outputs/x86_64-linux/src/k3s-prod-1-worker-3.nix index 913b883b..4e2e0254 100644 --- a/outputs/x86_64-linux/src/k3s-prod-1-worker-3.nix +++ b/outputs/x86_64-linux/src/k3s-prod-1-worker-3.nix @@ -20,7 +20,7 @@ # common "secrets/nixos.nix" "modules/nixos/server/server.nix" - "modules/nixos/server/proxmox-hardware-configuration.nix" + "modules/nixos/server/kubevirt-hardware-configuration.nix" # host specific "hosts/k8s/${name}" ]) @@ -36,6 +36,5 @@ in { colmena.${name} = mylib.colmenaSystem (systemArgs // {inherit tags ssh-user;}); - # generate proxmox image for virtual machines without desktop environment - packages.${name} = inputs.self.nixosConfigurations.${name}.config.formats.proxmox; + packages.${name} = inputs.self.nixosConfigurations.${name}.config.formats.kubevirt; } diff --git a/outputs/x86_64-linux/src/k3s-test-1-master-1.nix b/outputs/x86_64-linux/src/k3s-test-1-master-1.nix index 5c8e0fe8..61b5c042 100644 --- a/outputs/x86_64-linux/src/k3s-test-1-master-1.nix +++ b/outputs/x86_64-linux/src/k3s-test-1-master-1.nix @@ -39,6 +39,5 @@ in { colmena.${name} = mylib.colmenaSystem (systemArgs // {inherit tags ssh-user;}); - # generate proxmox image for virtual machines without desktop environment packages.${name} = inputs.self.nixosConfigurations.${name}.config.formats.kubevirt; } diff --git a/outputs/x86_64-linux/src/k3s-test-1-master-2.nix b/outputs/x86_64-linux/src/k3s-test-1-master-2.nix index c659c0ea..79c2b9cc 100644 --- a/outputs/x86_64-linux/src/k3s-test-1-master-2.nix +++ b/outputs/x86_64-linux/src/k3s-test-1-master-2.nix @@ -36,6 +36,5 @@ in { colmena.${name} = mylib.colmenaSystem (systemArgs // {inherit tags ssh-user;}); - # generate proxmox image for virtual machines without desktop environment packages.${name} = inputs.self.nixosConfigurations.${name}.config.formats.kubevirt; } diff --git a/outputs/x86_64-linux/src/k3s-test-1-master-3.nix b/outputs/x86_64-linux/src/k3s-test-1-master-3.nix index 2e6ac83f..1b6cd94a 100644 --- a/outputs/x86_64-linux/src/k3s-test-1-master-3.nix +++ b/outputs/x86_64-linux/src/k3s-test-1-master-3.nix @@ -36,6 +36,5 @@ in { colmena.${name} = mylib.colmenaSystem (systemArgs // {inherit tags ssh-user;}); - # generate proxmox image for virtual machines without desktop environment packages.${name} = inputs.self.nixosConfigurations.${name}.config.formats.kubevirt; } diff --git a/vars/networking.nix b/vars/networking.nix index bcbfc1c1..ad083e42 100644 --- a/vars/networking.nix +++ b/vars/networking.nix @@ -36,17 +36,17 @@ }; aquamarine = { # VM - iface = "ens18"; + iface = "eth1"; ipv4 = "192.168.5.101"; }; ruby = { # VM - iface = "ens18"; + iface = "eth1"; ipv4 = "192.168.5.102"; }; kana = { # VM - iface = "ens18"; + iface = "eth1"; ipv4 = "192.168.5.103"; }; nozomi = { @@ -61,7 +61,7 @@ }; chiaya = { # VM - iface = "ens18"; + iface = "eth1"; ipv4 = "192.168.5.106"; }; suzu = { @@ -90,32 +90,32 @@ # ============================================ k3s-prod-1-master-1 = { # VM - iface = "ens18"; + iface = "eth1"; ipv4 = "192.168.5.108"; }; k3s-prod-1-master-2 = { # VM - iface = "ens18"; + iface = "eth1"; ipv4 = "192.168.5.109"; }; k3s-prod-1-master-3 = { # VM - iface = "ens18"; + iface = "eth1"; ipv4 = "192.168.5.110"; }; k3s-prod-1-worker-1 = { # VM - iface = "ens18"; + iface = "eth1"; ipv4 = "192.168.5.111"; }; k3s-prod-1-worker-2 = { # VM - iface = "ens18"; + iface = "eth1"; ipv4 = "192.168.5.112"; }; k3s-prod-1-worker-3 = { # VM - iface = "ens18"; + iface = "eth1"; ipv4 = "192.168.5.113"; };