about summary refs log tree commit diff
path: root/machines/labnet/labtops.nix
diff options
context:
space:
mode:
authorProfpatsch <mail@profpatsch.de>2017-07-08 22:21:57 +0200
committerProfpatsch <mail@profpatsch.de>2017-07-08 23:53:35 +0200
commite8e506de9b3b1cddd4f4cb9edb85f1e292a2b1e1 (patch)
treec8c9b332236f98caad3a7fb1343df808940e68ac /machines/labnet/labtops.nix
parentf278c9189adf24f0f611d00297710579da3fa730 (diff)
machines/hannswurscht: serve speedtest output with nginx
Diffstat (limited to 'machines/labnet/labtops.nix')
-rw-r--r--machines/labnet/labtops.nix17
1 files changed, 15 insertions, 2 deletions
diff --git a/machines/labnet/labtops.nix b/machines/labnet/labtops.nix
index 29ea5507..f8393b34 100644
--- a/machines/labnet/labtops.nix
+++ b/machines/labnet/labtops.nix
@@ -15,7 +15,8 @@
   };
 
   hannswurscht = { pkgs, ... }:
-    let musicDir = "/data/music"; in
+    let musicDir = "/data/music";
+        webserverRootDir = "/var/www"; in
   {
     vuizvui.user.openlab.base.enable = true;
 
@@ -46,8 +47,20 @@
       enable = true;
       volume = 40;
     };
-    vuizvui.user.openlab.speedtest.enable = true;
+    vuizvui.user.openlab.speedtest = {
+      enable = true;
+      outputPath = "${webserverRootDir}/speedtest.yaml";
+    };
+
+    services.nginx = {
+      enable = true;
+      virtualHosts."hannswurscht.openlab.lan" = {
+        default = true;
+        root = webserverRootDir;
+      };
+    };
 
+    # machine mostly runs headless with the screen shut
     services.logind.extraConfig = "HandleLidSwitch=ignore";
 
     fileSystems = {