Commit graph iac/nixos/hosts/asxpio-ops/apps.nix
Author SHA1 Message Date
998ce26478
ops: no more app containers on Postgres and Garage
All checks were successful
nixos / nixos (push) Successful in 24s
asxpio, datacenterbingo, blog and czsk run on asxpio-services now and
reach Postgres and Garage over the private network; vhpbot, the last
container, uses neither. So Postgres no longer admits Podman's networks,
the firewall no longer opens 5432 and 3900 to them, and the container
plumbing for the Docker-era storage stack goes: the postgres/garage host
aliases and the empty storage network.

Assisted-by: Claude:opus-5-5
2026-11-17 14:21:00 +04:00
1a3d283e63
asxpio: container removed; its monitor runs on services now
All checks were successful
nixos / nixos (push) Successful in 24s
The asxpio and asxpio-monitor containers, their images and /opt/asxpio
are gone from asxpio-ops, so the native monitor worker starts and the
routes no longer have to outrank container labels.

Assisted-by: Claude:opus-5-5
2026-11-17 14:16:20 +04:00
1100800576
datacenterbingo: container removed, its route needs no priority
All checks were successful
nixos / nixos (push) Successful in 23s
Assisted-by: Claude:opus-5-5
2026-11-17 13:57:07 +04:00
9cd41e7543
czsk: container removed, its route needs no priority
All checks were successful
nixos / nixos (push) Successful in 22s
Assisted-by: Claude:opus-5-5
2026-11-17 13:33:18 +04:00
677c7eb34a
blog: container removed, its route needs no priority
All checks were successful
nixos / nixos (push) Successful in 21s
The blog container and /opt/blog are gone from asxpio-ops, so the route
to the NixOS service no longer has to outrank its labels.

Assisted-by: Claude:opus-5-5
2026-11-17 13:13:24 +04:00
2ca56d595c
nixos: containers come back after a reboot; ops-data.sh fixes
All checks were successful
nixos / nixos (push) Successful in 44s
Found by rehearsing the ops conversion on a fresh test server with last
night's backup:

- After a reboot the app containers stayed stopped. Docker restarted
  them; Podman does so only through podman-restart.service, which it
  ships but does not enable. Enable it; on ops it waits for the app
  networks, Postgres and Garage.
- ops-data.sh: a fresh NixOS has no /opt, so moving the app directories
  failed; and NixOS creates an empty /var/lib/forgejo/repositories at
  boot, so the repositories were moved into it, one level too deep.
  Every part now creates its target, replaces what is empty and skips
  what already moved, so an interrupted run can be resumed.
- `forgejo admin regenerate hooks` is gone in Forgejo 17, which gives
  git its own hooks on every push; a push to a restored repository
  works with the old hook files in place. Drop the call.
- The rehearsal ops host does not push XMPP certificates: there is no
  services host behind 10.10.0.20 on the test network.

Assisted-by: Claude:opus-5-5
2026-11-17 08:27:35 +04:00
fa46d26f89
nixos: app stacks on Podman, unchanged
The apps keep deploying themselves: their CI copies a compose file and
a .env and runs docker compose as user deploy. `docker` is now the real
Docker CLI against rootful Podman's socket, so compose, inspect and
logs behave as before and every user sees the same containers.

Their compose files still expect the storage stack's network and the
hosts postgres and garage. On ops every container resolves those two
names to the host, where the native services run, and an empty storage
network exists, so nothing in the app repositories has to change for
the move itself.

Tried on the rehearsal pair with the real asxpio and datacenterbingo
images on the restored database and Garage (mail and IndexNow
disabled): both serve through Traefik, and a local compose build works.

One thing does need the app repositories: Podman ignores the
HEALTHCHECK of OCI-format images, which is what the CI builds, so the
deploy's wait for "healthy" would time out. Declaring the healthcheck
in each compose file fixes it, also under Docker; see MIGRATION.md.

ops-data.sh now also moves the monitoring history, Traefik's
certificates and the app directories, and pulls the images again.

Assisted-by: Claude:opus-5-5
2026-11-17 05:11:17 +04:00