Move Garage and garage-webui to stpcore
Test and deploy / test (push) Successful in 18s
Test and deploy / deploy (push) Successful in 30s

Garage now runs on the stpcore LXC (adamf/stpcore), the shared core
other stacks depend on. caddy, backend and usaco pin the name `garage`
to it with GARAGE_UPSTREAM; /garage/ goes to stpcore's Caddy with
X-Core-Token. The disk fallback for /uploads/ is unchanged.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
2026-11-26 14:32:33 +00:00
co-authored by Claude Opus 5.5
parent d0ff2e125b
commit 223c8ae35a
13 changed files with 108 additions and 237 deletions
+24 -26
View File
@@ -197,13 +197,12 @@ USACO_CLAUDE_MONTHLY_BUDGET=
# Claude cannot take audio, so this OpenAI key transcribes it (whisper-1,
# about $0.006 a minute). Blank turns reviews off.
USACO_OPENAI_API_KEY=
# Optional: keep the recordings for playback in a PRIVATE Garage bucket,
# never `uploads` (that one is served publicly at /uploads/). Its own key,
# same shapes as S3_ACCESS_KEY_ID / S3_SECRET_ACCESS_KEY above. With the
# key blank the recordings are thrown away once transcribed. One-off setup:
# docker compose exec -T garage /garage bucket create usaco-audio
# docker compose exec -T garage /garage key import -n usaco-site --yes "$USACO_S3_ACCESS_KEY_ID" "$USACO_S3_SECRET_ACCESS_KEY"
# docker compose exec -T garage /garage bucket allow --read --write usaco-audio --key "$USACO_S3_ACCESS_KEY_ID"
# Optional: keep the recordings for playback in a PRIVATE Garage bucket
# (`usaco-audio` on stpcore), never `uploads` (that one is served publicly at
# /uploads/). Its own key, same shapes as S3_ACCESS_KEY_ID /
# S3_SECRET_ACCESS_KEY below. With the key blank the recordings are thrown
# away once transcribed. Put the same pair in stpcore's .env and run its
# garage/bootstrap.sh, which creates the bucket and imports the key.
USACO_S3_ACCESS_KEY_ID=
USACO_S3_SECRET_ACCESS_KEY=
@@ -242,30 +241,29 @@ STPPRIV_LAN_IP=
# TfL Unified API key (500 req/min); used by the Python hotel finder
TFL_APP_KEY=
# --- Garage object store (public /uploads/) -----------------------------------
# See garage/garage.toml and DEPLOYMENT.md ("Garage"). Everything here is
# optional for the site to run: with S3_ENDPOINT blank the backend keeps
# writing uploads to the `uploads` volume exactly as before.
# --- Garage object store (public /uploads/, on stpcore) -----------------------
# Garage runs on the stpcore LXC (adamf/stpcore); its README is the runbook
# and its .env holds Garage's own secrets. Everything here is optional for
# the site to run: with S3_ENDPOINT blank, or stpcore down, the backend
# writes uploads to the `uploads` volume and Caddy serves them from there.
#
# Garage's own secrets, passed to the garage and garage-webui containers.
# Generate each with `openssl rand -hex 32`. The RPC secret must never change
# once the node has data; the admin token unlocks garage-webui's whole API.
GARAGE_RPC_SECRET=
GARAGE_ADMIN_TOKEN=
# The backend's S3 access, imported into Garage by garage/bootstrap.sh.
# Garage only accepts this shape:
# stpcore's LAN IP: the name `garage` is pinned to it in caddy, backend and
# usaco. `host-gateway` in dev. Blank means 127.0.0.1, which fails fast.
GARAGE_UPSTREAM=
# Shared secret Caddy adds as X-Core-Token on /garage/, after the admin
# gate; the same value as GARAGE_WEBUI_TOKEN in stpcore's .env.
# `openssl rand -hex 32`. Changing it needs `docker compose up -d caddy`.
GARAGE_WEBUI_TOKEN=
# The backend's S3 key, the same values as in stpcore's .env (whose
# bootstrap.sh imports it). Garage only accepts this shape:
# S3_ACCESS_KEY_ID "GK" + 24 hex (echo GK$(openssl rand -hex 12))
# S3_SECRET_ACCESS_KEY 64 hex (openssl rand -hex 32)
S3_ACCESS_KEY_ID=
S3_SECRET_ACCESS_KEY=
# Blank keeps uploads on disk. Set to http://garage:3900 (after running
# garage/bootstrap.sh) to store new public uploads in the bucket; recreate the
# backend after changing it. If a write to Garage fails the backend logs it and
# writes to disk instead, and Caddy serves the file from there.
# Blank keeps uploads on disk. http://garage:3900 stores new public uploads
# in the bucket; recreate the backend after changing it. If a write to Garage
# fails the backend logs it and writes to disk instead.
S3_ENDPOINT=
# Optional; these defaults match garage.toml and bootstrap.sh.
# Optional; these defaults match stpcore's garage.toml and bootstrap.sh.
S3_REGION=garage
S3_BUCKET=uploads
# Optional, bootstrap.sh only: the node's capacity in the layout. With one node
# it only has to be non-zero; it is not a quota. Default 20G.
GARAGE_CAPACITY=