From f29a8410cedae23531a6694dfc3ecf87ff0ce26b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?m=C3=BCde?= Date: Sun, 18 Oct 2026 03:36:15 +0200 Subject: [PATCH] add truth machine --- flake.lock | 21 +++++++++++++++++++ flake.nix | 4 ++++ nixosConfigurations/hyperforge/default.nix | 1 + .../hyperforge/truth-machine.nix | 21 +++++++++++++++++++ 4 files changed, 47 insertions(+) create mode 100644 nixosConfigurations/hyperforge/truth-machine.nix diff --git a/flake.lock b/flake.lock index 1edbf8e..156afb6 100644 --- a/flake.lock +++ b/flake.lock @@ -799,6 +799,7 @@ "stylix": "stylix", "treefmt-nix": "treefmt-nix_2", "trollshell": "trollshell", + "truth-machine": "truth-machine", "zerforschen-plus": "zerforschen-plus" } }, @@ -1091,6 +1092,26 @@ "type": "github" } }, + "truth-machine": { + "inputs": { + "nixpkgs": [ + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1792286440, + "narHash": "sha256-B9NYbg7xyzSrP/+g70jp0PfyikylMoPw7XAOCltHn6c=", + "ref": "refs/heads/main", + "rev": "a874d5d119847413be78f21f25868d668498c7c8", + "revCount": 8, + "type": "git", + "url": "https://forge.darkest.space/mara/truth.bat.git" + }, + "original": { + "type": "git", + "url": "https://forge.darkest.space/mara/truth.bat.git" + } + }, "xwayland-satellite-stable": { "flake": false, "locked": { diff --git a/flake.nix b/flake.nix index 3123aaa..0774a1f 100644 --- a/flake.nix +++ b/flake.nix @@ -97,6 +97,10 @@ home-manager.follows = "home-manager"; }; }; + truth-machine = { + url = "git+https://forge.darkest.space/mara/truth.bat.git"; + inputs.nixpkgs.follows = "nixpkgs"; + }; zerforschen-plus = { url = "git+https://forge.darkest.space/mara/zerforschen.plus.git"; inputs.nixpkgs.follows = "nixpkgs"; diff --git a/nixosConfigurations/hyperforge/default.nix b/nixosConfigurations/hyperforge/default.nix index bf733fb..4a46d0c 100644 --- a/nixosConfigurations/hyperforge/default.nix +++ b/nixosConfigurations/hyperforge/default.nix @@ -3,6 +3,7 @@ ./hardware.nix ./forgejo.nix ./nginx.nix + ./truth-machine.nix ]; config = { diff --git a/nixosConfigurations/hyperforge/truth-machine.nix b/nixosConfigurations/hyperforge/truth-machine.nix new file mode 100644 index 0000000..72737b3 --- /dev/null +++ b/nixosConfigurations/hyperforge/truth-machine.nix @@ -0,0 +1,21 @@ +{ truth-machine, ... }: +let + domain = "truth.darkest.space"; +in +{ + imports = [ truth-machine.nixosModules.default ]; + + services = { + truth-machine = { + enable = true; + virtualHost = domain; + # ANTHROPIC_API_KEY, TRUTH_ADMIN_PASSWORD and TRUTH_ADMIN_PATH, placed manually + environmentFile = "/etc/secrets/truth-machine.env"; + }; + + nginx.virtualHosts.${domain} = { + enableACME = true; + forceSSL = true; + }; + }; +}