From 353fdd896dc8d33620dc7685fb76176b872895bf Mon Sep 17 00:00:00 2001 From: Mel Date: Thu, 17 Apr 2025 03:41:56 +0200 Subject: Serve Mainsail on `3d.rnrd.fyi` from fourmi Signed-off-by: Mel --- modules/klipper.nix | 27 +++++++++++++++++++++++---- 1 file changed, 23 insertions(+), 4 deletions(-) (limited to 'modules/klipper.nix') diff --git a/modules/klipper.nix b/modules/klipper.nix index f23e66c..4f7be74 100644 --- a/modules/klipper.nix +++ b/modules/klipper.nix @@ -56,18 +56,37 @@ in settings = { authorization = { cors_domains = [ - "https://app.fluidd.xyz" - "https://my.mainsail.xyz" - "https://*.rnrd.fyi" + "*://app.fluidd.xyz" + "*://my.mainsail.xyz" + "*://*.rnrd.fyi" ]; trusted_clients = [ "10.0.0.0/8" - "127.0.0.1/24" + "100.0.0.0/8" + "127.0.0.0/24" "192.168.178.0/24" ]; }; }; }; + + mainsail = { + enable = true; + hostName = "3d.rnrd.fyi"; + + nginx = { + useACMEHost = "rnrd.fyi"; + forceSSL = true; + listenAddresses = [ me.tailscale.ip ]; + + extraConfig = '' + access_log /var/log/nginx/3d.access.log json_combined; + ''; + }; + }; + + # don't reject large gcode files etc. + nginx.clientMaxBodySize = "1000M"; }; } -- cgit 1.4.1