about summary refs log tree commit diff
path: root/ops/modules/www
diff options
context:
space:
mode:
Diffstat (limited to 'ops/modules/www')
-rw-r--r--ops/modules/www/inbox.tvl.su.nix24
1 files changed, 24 insertions, 0 deletions
diff --git a/ops/modules/www/inbox.tvl.su.nix b/ops/modules/www/inbox.tvl.su.nix
new file mode 100644
index 000000000000..a9af18e3481b
--- /dev/null
+++ b/ops/modules/www/inbox.tvl.su.nix
@@ -0,0 +1,24 @@
+{ config, ... }:
+
+{
+  imports = [
+    ./base.nix
+  ];
+
+  config = {
+    services.nginx.virtualHosts."inbox.tvl.su" = {
+      enableACME = true;
+      forceSSL = true;
+
+      extraConfig = ''
+        location = / {
+          return 302 https://inbox.tvl.su/depot;
+        }
+
+        location / {
+          proxy_pass http://localhost:${toString config.services.public-inbox.http.port};
+        }
+      '';
+    };
+  };
+}