feat: add backup for server
This commit is contained in:
parent
20ee47caa2
commit
f7409e0537
14 changed files with 256 additions and 165 deletions
|
|
@ -1,42 +1,16 @@
|
|||
{
|
||||
pkgs,
|
||||
config,
|
||||
username,
|
||||
...
|
||||
}:
|
||||
{
|
||||
programs.virt-manager.enable = true;
|
||||
users.groups.libvirtd.members = [ username ];
|
||||
|
||||
virtualisation = {
|
||||
docker.enable = true;
|
||||
|
||||
# Run container as systemd service
|
||||
oci-containers = {
|
||||
backend = "docker";
|
||||
backend = "podman";
|
||||
containers = { };
|
||||
};
|
||||
|
||||
libvirtd = {
|
||||
enable = true;
|
||||
qemu = {
|
||||
package = pkgs.qemu_kvm;
|
||||
swtpm.enable = true;
|
||||
ovmf.enable = true;
|
||||
ovmf.packages = [ pkgs.OVMFFull.fd ];
|
||||
};
|
||||
};
|
||||
|
||||
spiceUSBRedirection.enable = true;
|
||||
};
|
||||
|
||||
environment.etc = {
|
||||
"ovmf/edk2-x86_64-secure-code.fd" = {
|
||||
source = config.virtualisation.libvirtd.qemu.package + "/share/qemu/edk2-x86_64-secure-code.fd";
|
||||
};
|
||||
|
||||
"ovmf/edk2-i386-vars.fd" = {
|
||||
source = config.virtualisation.libvirtd.qemu.package + "/share/qemu/edk2-i386-vars.fd";
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue