From f052d9d26b9a56a8e619f77e7861f243b35e7461 Mon Sep 17 00:00:00 2001 From: Maurice Date: Tue, 25 Aug 2026 22:53:49 +0200 Subject: [PATCH] docs: the storage seed example lives in the wiki now Admin-Storage pointed at the README's Storage section for the seed file example and the compose mount line. That section is gone, so the link went nowhere and the example existed in no copy at all - the wiki page described storage-config.json without ever showing one. Both are on the page now. The commented mount in docker-compose.yml pointed at the same removed section. --- docker-compose.yml | 2 +- wiki/Admin-Storage.md | 25 +++++++++++++++++++++++-- 2 files changed, 24 insertions(+), 3 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index 1e5ee4d53..4b414c180 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -53,7 +53,7 @@ services: volumes: - ./data:/app/data - ./uploads:/app/uploads -# - ./storage-config.json:/app/data/storage-config.json:ro # optional seed-once storage provisioning (README → Storage) +# - ./storage-config.json:/app/data/storage-config.json:ro # optional seed-once storage provisioning (wiki: Admin-Storage) restart: unless-stopped healthcheck: test: ["CMD", "wget", "-qO-", "http://localhost:3000/api/health"] diff --git a/wiki/Admin-Storage.md b/wiki/Admin-Storage.md index e9f473fdb..3e144e658 100644 --- a/wiki/Admin-Storage.md +++ b/wiki/Admin-Storage.md @@ -143,8 +143,29 @@ For scripted deployments, place a `storage-config.json` in the data directory (in Docker: mount it at `/app/data/storage-config.json`). It is imported exactly once — on the first boot that has no stored storage configuration — then ignored (a log line says so). An invalid file aborts boot with the exact -validation error. Example and the compose mount line: see the -[README Storage section](https://github.com/liketrek/TREK#storage). +validation error. + +```jsonc +// storage-config.json - secrets may be plaintext (encrypted on import) +// or already-encrypted enc:v1: values. +{ + "backends": [ + { "name": "off-site", "type": "s3", "options": { + "endpoint": "https://s3.example.com", "bucket": "trek", + "accessKeyId": "...", "secretAccessKey": "..." } }, + { "name": "backups-mirror", "type": "mirror", "options": { + "primary": "backups-local", "replicas": ["off-site"] } } + ], + "categories": { "backups": "backups-mirror" } +} +``` + +The panel presents this exact setup as **Mirror targets** on `backups-local`. + +```yaml +# docker-compose: add under the trek service's volumes + - ./storage-config.json:/app/data/storage-config.json:ro +``` To reset storage configuration (or re-import a seed file): stop the server, `sqlite3 data/travel.db "DELETE FROM app_settings WHERE key LIKE 'storage.%';"`,