From a8c0b1aabcd6c65bfbf474a38d2c90547c48de79 Mon Sep 17 00:00:00 2001 From: sefidel Date: Tue, 9 Apr 2024 22:04:42 +0900 Subject: feat(nixos/kanata): web change detection wip --- nixos/kanata/configuration.nix | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) (limited to 'nixos/kanata/configuration.nix') diff --git a/nixos/kanata/configuration.nix b/nixos/kanata/configuration.nix index 9e3f330..a5ed1be 100644 --- a/nixos/kanata/configuration.nix +++ b/nixos/kanata/configuration.nix @@ -159,6 +159,7 @@ in "cache.kusanari.network".to = "http://localhost:4005"; "torrent.kusanari.network".to = "http://localhost:4006"; "paperless.kusanari.network".to = "http://localhost:4007"; + "change.labs.kusanari.network".to = "http://localhost:4901"; # Nginx pre-configured routes "nextcloud.kusanari.network" = { @@ -284,6 +285,29 @@ in }; }; + services.changedetection-io = { + enable = true; + + listenAddress = "localhost"; + port = 4901; + + baseURL = "https://change.labs.kusanari.network"; + behindProxy = true; + webDriverSupport = true; + }; + + services.nginx.virtualHosts."change.labs.kusanari.network".locations."/" = { + proxyWebsockets = true; + extraConfig = '' + proxy_redirect off; + proxy_set_header Host $host; + proxy_set_header X-Real-IP $remote_addr; + proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; + proxy_set_header X-Forwarded-Proto $scheme; + proxy_set_header Referer "https://change.labs.kusanari.network"; + ''; + }; + containers.v-interlink = { autoStart = true; enableTun = true; -- cgit 1.4.1