diff options
author | Emile <git@emile.space> | 2025-02-10 23:58:05 +0100 |
---|---|---|
committer | Emile <git@emile.space> | 2025-02-10 23:58:05 +0100 |
commit | 906026e924e3aac0f0ed32ec8ab2f7468e8e1c0a (patch) | |
tree | cadcd8aa380b713a573266701d0b63b766c93b97 /nix/hosts/corrino | |
parent | f62271e0d0739cbc7a4fae21ebfcd76e0e7e9d58 (diff) |
corrino: libvirtnix foo, less XML, more nix!
So I've finally started this. Let's see how far I can push this!
Diffstat (limited to 'nix/hosts/corrino')
-rw-r--r-- | nix/hosts/corrino/configuration.nix | 1 | ||||
-rw-r--r-- | nix/hosts/corrino/vm.nix | 43 |
2 files changed, 44 insertions, 0 deletions
diff --git a/nix/hosts/corrino/configuration.nix b/nix/hosts/corrino/configuration.nix index f5f6444..f69d16a 100644 --- a/nix/hosts/corrino/configuration.nix +++ b/nix/hosts/corrino/configuration.nix @@ -22,6 +22,7 @@ in ./hardware-configuration.nix ./ports.nix + ./vm.nix ./www/git ./www/nix-cache diff --git a/nix/hosts/corrino/vm.nix b/nix/hosts/corrino/vm.nix new file mode 100644 index 0000000..7fcf4af --- /dev/null +++ b/nix/hosts/corrino/vm.nix @@ -0,0 +1,43 @@ +{ pkgs, ... }: + +{ + services.emile.libvirtnix = { + enable = true; + instances = { + + vm1 = { + domain = { + name = "VM1"; + title = "vm one"; + description = "The first VM"; + id = 1; + + uuid = "E34DE478-1402-45BB-B3FD-FC960549258E"; + genid = "CA1E2462-1E9D-404C-8DDB-19EEF9D9651B"; + + packages = { + libvirt = pkgs.libvirt; + qemu = pkgs.qemu; + }; + memory = 1024; + }; + }; + + vm2 = { + domain = { + name = "VM2"; + title = "vm one"; + description = "The second VM"; + id = 2; + + uuid = "E34DE478-1402-45BB-B3FD-FC960549258E"; + genid = "002D0D8F-B21A-4001-92BF-2313707EED9D"; + + memory = 2048; + }; + }; + + }; + }; +} + |