Add an `id.nul.ie` OpenID Connect login source to Gitea, kept up to date from `preStart` since Gitea stores login sources in its database. Its client is declared on `middleman` with the secret shared by both. Registration stays disabled, so a Pocket ID sign-in links to an existing account. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
3.3 KiB
3.3 KiB
git
The Gitea VM — source hosting and CI for the boxes (git.nul.ie).
- Source:
nixos/boxes/colony/vms/git/(default.nix,gitea.nix,gitea-actions.nix) - Host: VM on
colony - nixpkgs:
mine
Role
Gitea
The Git forge at git.nul.ie (self-registration disabled), configured in
gitea.nix.
- Backed by PostgreSQL on
colony-psql(waited on vialib.my.systemdAwaitPostgres). - LFS enabled; all object storage (incl. LFS and packages) is on MinIO at
s3.nul.ie(bucketgitea, onobject) — the secret is spliced intoapp.iniat startup. - Mail goes out via
mail.nul.ie, including the issue-reply incoming-mail poller. - Sign-in with Pocket ID:
preStartadds or updates theid.nul.ieOpenID Connect login source. The clientgiteaand its secretgitea/oidc-secret.txtare declared onmiddleman.- Registration stays disabled, so a Pocket ID sign-in can't create an account. The first one links to an existing account after signing in with its password.
- It runs before the server, which only reads login sources at startup. If it fails, Gitea starts without the source and logs a warning.
- The CLI only takes the secret as an argument, so it is briefly visible in the process list
while
preStartruns.
Gitea Actions runner
One Docker-mode instance (main-docker) on podman (privileged, podman network), configured in
gitea-actions.nix.
- Labels for
node:24-trixieand the self-builtgit.nul.ie/dev/actions-ubuntu:26.04images. - Runs as a fixed
gitea-runneruser (notDynamicUser) so it can read its token; jobs have a configured timeout. - Gitea's
actions.ENDLESS_TASK_TIMEOUTmatches the runner's job timeout. Otherwise the server's shorter default marks long builds as failed while the runner keeps working on them. - The action cache lives on a dedicated disk (
/var/cache/gitea-runner). - Executes the repo's own
.gitea/workflows/ci.yaml.
nginx
Terminates TLS for git.nul.ie (and a default vhost) and proxies to Gitea on :3000. ACME
(Let's Encrypt, production) issues nul.ie + *.nul.ie via the Cloudflare DNS-01 challenge.
podman
Local container backend for the runner; /var/lib/containers is an XFS data disk, and the default
10.88.0.0/16 podman subnet is allowed to forward.
Network assignments
See the consolidated network assignments table (this box: git).
Storage
/var/lib/gitea— thegitLV (repositories, config)./var/cache/gitea-runner— thegitea-actions-cacheLV./var/lib/containers— theociLV (XFS with project quotas). Despite the name this is local to thegitVM and unrelated towhale2'socinetwork.
Notable config files
nixos/boxes/colony/vms/git/default.nix— VM config, nginx + ACME, podman, firewall.nixos/boxes/colony/vms/git/gitea.nix— Gitea itself.nixos/boxes/colony/vms/git/gitea-actions.nix— the Actions runner.