From 6f3b557e9eb22eb862c7afde7453962c86455a43 Mon Sep 17 00:00:00 2001 From: Marcel Date: Mon, 10 Jun 2024 13:33:05 +0200 Subject: [PATCH] kindergarten: cleanup --- flake.lock | 80 +++++++++++++++++++++++---- flake.nix | 1 - modules/data-hoarder/kindergarten.nix | 10 +--- 3 files changed, 71 insertions(+), 20 deletions(-) diff --git a/flake.lock b/flake.lock index 89d57d5..5e2ab44 100644 --- a/flake.lock +++ b/flake.lock @@ -298,6 +298,41 @@ "type": "github" } }, + "flake-utils_2": { + "inputs": { + "systems": "systems_3" + }, + "locked": { + "lastModified": 1710146030, + "narHash": "sha256-SZ5L6eA7HJ/nmkzGG7/ISclqe6oZdOZTNoesiInkXPQ=", + "owner": "numtide", + "repo": "flake-utils", + "rev": "b1d9ab70662946ef0850d488da1c9019f3a9752a", + "type": "github" + }, + "original": { + "id": "flake-utils", + "type": "indirect" + } + }, + "flake-utils_3": { + "inputs": { + "systems": "systems_4" + }, + "locked": { + "lastModified": 1701680307, + "narHash": "sha256-kAuep2h5ajznlPMD9rnQyffWG8EM/C73lejGofXvdM8=", + "owner": "numtide", + "repo": "flake-utils", + "rev": "4022d587cbbfd70fe950c1e2083a02621806a725", + "type": "github" + }, + "original": { + "owner": "numtide", + "repo": "flake-utils", + "type": "github" + } + }, "funnel": { "inputs": { "json-structs": "json-structs", @@ -341,20 +376,18 @@ }, "kindergarten": { "inputs": { - "flake-utils": [ - "flake-utils" - ], + "flake-utils": "flake-utils_2", "nixpkgs": [ "nixpkgs" ], "pnpm2nix": "pnpm2nix" }, "locked": { - "lastModified": 1716148172, - "narHash": "sha256-+rKHw/bkFXiqPtVRtY/A5ER0DDdgp4aFn/6iGoE4y8s=", + "lastModified": 1718019089, + "narHash": "sha256-bZELxLQjx8jzxj2KOSCxhI7UWpbYOJ2xl5H1F6kmCzs=", "owner": "tlm-solutions", "repo": "kindergarten", - "rev": "7f9f8d229528ee4542a4734423af26d2eb6c6b24", + "rev": "c2cab4e71ce6d508b822ac91ef8614069db645f1", "type": "github" }, "original": { @@ -625,10 +658,7 @@ }, "pnpm2nix": { "inputs": { - "flake-utils": [ - "kindergarten", - "flake-utils" - ], + "flake-utils": "flake-utils_3", "nixpkgs": [ "kindergarten", "nixpkgs" @@ -882,6 +912,36 @@ "type": "github" } }, + "systems_3": { + "locked": { + "lastModified": 1681028828, + "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", + "owner": "nix-systems", + "repo": "default", + "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", + "type": "github" + }, + "original": { + "owner": "nix-systems", + "repo": "default", + "type": "github" + } + }, + "systems_4": { + "locked": { + "lastModified": 1681028828, + "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", + "owner": "nix-systems", + "repo": "default", + "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", + "type": "github" + }, + "original": { + "owner": "nix-systems", + "repo": "default", + "type": "github" + } + }, "telegram-decoder": { "inputs": { "naersk": [ diff --git a/flake.nix b/flake.nix index 0feac3f..9beab91 100644 --- a/flake.nix +++ b/flake.nix @@ -52,7 +52,6 @@ url = "github:tlm-solutions/kindergarten"; inputs = { nixpkgs.follows = "nixpkgs"; - flake-utils.follows = "flake-utils"; }; }; diff --git a/modules/data-hoarder/kindergarten.nix b/modules/data-hoarder/kindergarten.nix index 71fdc4b..acf3734 100644 --- a/modules/data-hoarder/kindergarten.nix +++ b/modules/data-hoarder/kindergarten.nix @@ -16,16 +16,8 @@ enableACME = true; forceSSL = true; locations."~ ^/(de|en)" = { - root = - if (config.deployment-TLMS.domain == "tlm.solutions") then - "${pkgs.kindergarten}" - else - "${pkgs.kindergarten-staging}"; - # index = "index.html"; + root = "${pkgs.kindergarten.override {inherit (config.deployment-TLMS ) domain; }}"; tryFiles = "$uri /$1/index.html =404"; - extraConfig = '' - more_set_headers "Access-Control-Allow-Credentials: true"; - ''; }; locations."~ ^/(?!en|de)" = { extraConfig = ''