Add guildhall

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
rope 2026-10-18 13:55:14 +01:00
parent a985148346
commit 791a3bdf34
6 changed files with 53 additions and 0 deletions

View file

@ -49,6 +49,7 @@ in
{ domain = "reddit.nordhammer.it"; policy = "one_factor"; }
{ domain = "panel.nordhammer.it"; policy = "one_factor"; subject = admin; }
{ domain = "stardew.nordhammer.it"; policy = "one_factor"; }
{ domain = "guildhall.nordhammer.it"; policy = "one_factor"; }
# Health data: only the two people the app knows about.
{ domain = "flowtrack.nordhammer.it"; policy = "one_factor"; subject = [ "user:kayla" "user:fred" ]; }
];

16
services/guildhall.nix Normal file
View file

@ -0,0 +1,16 @@
# services/guildhall.nix — Guildhall, the co-op idle game for friends.
#
# The game and NixOS module live in the standalone guildhall flake. nginx is
# the only public listener; Authelia admits any account, and the game keys
# each player on the Remote-User it passes through. Nightly snapshots sit
# next to flowtrack's on the SSD branch of the pool.
{ config, lib, ... }:
{
config = lib.mkIf (config.networking.hostName == "FredOS-Mediaserver") {
services.guildhall = {
enable = true;
port = 8098;
backup.directory = "/mnt/disk2/backups/guildhall";
};
};
}

View file

@ -210,6 +210,13 @@ in
proxy_set_header Remote-User $user;
'';
};
# Co-op idle game. Players are keyed on Remote-User, so nginx must
# always overwrite it with the Authelia identity.
"guildhall.nordhammer.it" = lib.recursiveUpdate (protectedProxy 8098) {
locations."/".extraConfig = autheliaAuthConfig + ''
proxy_set_header Remote-User $user;
'';
};
# Pelican game panel. Can't turn off its own login (no such option
# upstream), so Authelia is the outer gate and the Pelican account