middleman: Replace nginx-sso with Pocket ID SSO
Gate the vhosts without their own sign-in with oauth2-proxy, which signs in with Pocket ID and allows members of the `admins` group. Each gated vhost serves its own `/oauth2/` endpoints with a host-only session cookie, so other `.nul.ie` sites never receive it. Sessions last a week, and a refresh token lets oauth2-proxy check back with Pocket ID every hour without a passkey. Add `my.pocket-id`, which declares Pocket ID groups and OIDC clients in Nix; `pocket-id-sync` applies them through the API with a static API key that nginx keeps from outside requests. This lets apps move to Pocket ID with their client defined next to them, with secrets from `slop secret generate`. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit was merged in pull request #12.
This commit is contained in:
1 parent
a3950b9bb3
commit
eeb1f2d15c
14 files changed
+514
-325
No files matched your search
@@ -187,7 +187,7 @@ descriptions) see [`reference/nixos-options.md`](reference/nixos-options.md).
|
||||
| `vms` | `my.vms.instances` — QEMU/KVM VMs as systemd units: TAP/bridge networking, LVM-backed disks, VFIO host-device passthrough (with udev tagging), UEFI, SPICE/TTY/QMP unix sockets under `/run/vms/`, clean shutdown via QMP `system_powerdown`. |
|
||||
| `network` | Baseline networking: networkd only (`useDHCP = false`), IPv6 on, resolved domain/negative-cache settings; dev VMs get DHCP on `eth0` and an SSH port forward. |
|
||||
| `pdns` | `my.pdns` — PowerDNS: authoritative server driven by BIND-style zone files (with templating and serial management) and recursor extra-settings wiring. |
|
||||
| `nginx-sso` | `my.nginx-sso` — runs `nginx-sso` (instead of the stock NixOS module) and generates per-instance nginx `auth_request` include files. |
|
||||
| `pocket-id` | `my.pocket-id` — Pocket ID with user groups and OIDC clients declared in Nix; `pocket-id-sync` applies them through the API with a static API key. |
|
||||
| `gui` | `my.gui.enable` (default on) — desktop baseline: graphics, polkit, swaylock PAM entry, Android udev rules, screenshot tmpdir. |
|
||||
| `l2mesh` | Consumes `nixos.vpns.l2` — builds the VXLAN + IPsec layer-2 meshes between edge routers; see [networking.md](networking.md). |
|
||||
| `borgthin` | `my.borgthin.jobs` — borg backups of thin-LVM snapshots to local or SSH repos on a systemd timer, with pruning. |
|
||||
|
||||
Reference in new issue
Block a user