summaryrefslogtreecommitdiff
path: root/config/virtualisation.nix
diff options
context:
space:
mode:
Diffstat (limited to 'config/virtualisation.nix')
-rw-r--r--config/virtualisation.nix15
1 files changed, 15 insertions, 0 deletions
diff --git a/config/virtualisation.nix b/config/virtualisation.nix
new file mode 100644
index 0000000..498aa43
--- /dev/null
+++ b/config/virtualisation.nix
@@ -0,0 +1,15 @@
+{ config, lib, ... }:
+{
+ virtualisation.vmVariant = {
+ services.getty.autologinUser = "root";
+ virtualisation = {
+ memorySize = 4 * 1024;
+ cores = 4;
+ forwardPorts = map (port: {
+ from = "host";
+ host.port = port + 8000;
+ guest.port = port;
+ }) config.networking.firewall.allowedTCPPorts;
+ };
+ };
+}