immich update
This commit is contained in:
@@ -18,6 +18,7 @@ docker/ Docker app configs (compose files, nginx confs)
|
||||
jellyfin/ Media server
|
||||
garage/ S3-compatible storage
|
||||
minecraft/ MCSManager
|
||||
immich/ Immich photo server + PostgreSQL
|
||||
beszel-agent/ System monitoring agent (reports to beszel.hantim.net)
|
||||
smb/ Samba share (ZFS mountpoint, not in git)
|
||||
system/ System config snapshots (smb.conf, sanoid.conf, firewalld, etc.)
|
||||
@@ -84,6 +85,8 @@ See [RUNBOOK.md](RUNBOOK.md) for full disaster recovery steps.
|
||||
| Nextcloud files | ZFS mirror + sanoid snapshots + USB | `rsync` from USB |
|
||||
| Media library | ZFS raidz2 + sanoid snapshots + USB | `rsync` from USB |
|
||||
| Nextcloud DB (PostgreSQL) | ZFS dataset + `pg_dumpall` + USB | `rsync` from USB |
|
||||
| Immich library (photos/videos) | ZFS raidz2 + sanoid snapshots + USB | `rsync` from USB |
|
||||
| Immich DB (PostgreSQL) | `pg_dumpall` + USB | `rsync` from USB |
|
||||
| Garage S3 data | 2-node replication + USB | Replication or USB |
|
||||
| Gitea repos + DB | SQLite `.backup` + USB | `rsync` from USB |
|
||||
| Secrets (.env files) | USB backup + Bitwarden | `rsync` from USB, or recreate from Bitwarden |
|
||||
|
||||
+8
-3
@@ -91,11 +91,13 @@ zpool import threeteras
|
||||
zfs set mountpoint=/opt/argento/docker/nextcloud/data nextcloud/data
|
||||
zfs set mountpoint=/opt/argento/smb/media threeteras/media
|
||||
zfs set mountpoint=/opt/argento/docker/garage/data threeteras/garage
|
||||
zfs set mountpoint=/opt/argento/docker/immich/library threeteras/immich
|
||||
|
||||
zpool status # verify pools are ONLINE
|
||||
|
||||
# Restore non-ZFS app data (Gitea, Minecraft, Jellyfin config) from USB:
|
||||
rsync -a --exclude='docker/nextcloud/data/' --exclude='docker/garage/data/' --exclude='smb/' \
|
||||
rsync -a --exclude='docker/nextcloud/data/' --exclude='docker/garage/data/' \
|
||||
--exclude='docker/immich/library/' --exclude='smb/' \
|
||||
/mnt/backup/argento/ /opt/argento/
|
||||
```
|
||||
|
||||
@@ -117,6 +119,7 @@ zpool create threeteras raidz2 /dev/disk/by-id/<disk3> ... /dev/disk/by-id/<disk
|
||||
zfs set compression=lz4 threeteras
|
||||
zfs create -o mountpoint=/opt/argento/smb/media threeteras/media
|
||||
zfs create -o mountpoint=/opt/argento/docker/garage/data threeteras/garage
|
||||
zfs create -o mountpoint=/opt/argento/docker/immich/library threeteras/immich
|
||||
|
||||
zpool status # verify pools are ONLINE
|
||||
|
||||
@@ -171,7 +174,7 @@ docker compose up -d
|
||||
# Issue certs (add any new domains that have been added since this was written)
|
||||
/opt/argento/scripts/issue-cert.sh \
|
||||
nextcloud.timothykim.net git.timothykim.net jellyfin.timothykim.net \
|
||||
argento.timothykim.net garage.timothykim.net
|
||||
argento.timothykim.net garage.timothykim.net photos.thekims.family
|
||||
|
||||
# Restore SSL confs now that certs exist
|
||||
mv conf.d/.hold/*.conf conf.d/
|
||||
@@ -197,7 +200,7 @@ Deploy each app (nginx is already running and will return 502 until they start):
|
||||
|
||||
```bash
|
||||
# Add any new apps that have been added since this was written
|
||||
for app in nextcloud gitea jellyfin garage minecraft beszel-agent; do
|
||||
for app in nextcloud gitea jellyfin garage minecraft immich beszel-agent; do
|
||||
cd /opt/argento/docker/$app
|
||||
docker compose pull
|
||||
docker compose build
|
||||
@@ -229,6 +232,7 @@ CNAME records pointing to the DDNS hostname. These don't need updating when the
|
||||
| `argento.timothykim.net` | CNAME | `argento.ddns.net` |
|
||||
| `garage.timothykim.net` | CNAME | `argento.ddns.net` |
|
||||
| `minecraft.thekims.family` | CNAME | `argento.ddns.net` |
|
||||
| `photos.thekims.family` | CNAME | `argento.ddns.net` |
|
||||
|
||||
## 14. Verify
|
||||
|
||||
@@ -238,6 +242,7 @@ curl -I https://git.timothykim.net
|
||||
curl -I https://jellyfin.timothykim.net
|
||||
curl -I https://argento.timothykim.net
|
||||
curl -I https://garage.timothykim.net
|
||||
curl -I https://photos.thekims.family
|
||||
curl -I http://minecraft.thekims.family
|
||||
|
||||
# Verify SMART, ZFS, and disk space are healthy
|
||||
|
||||
@@ -18,6 +18,16 @@ else
|
||||
FAILURES+=("nextcloud pg_dump")
|
||||
fi
|
||||
|
||||
# Dump Immich PostgreSQL for consistency
|
||||
mkdir -p /opt/argento/docker/immich/db
|
||||
IMMICH_DB_USER=$(grep -E '^DB_USERNAME=' /opt/argento/docker/immich/.env | cut -d= -f2)
|
||||
if docker exec immich_postgres pg_dumpall -U "${IMMICH_DB_USER:-postgres}" > /opt/argento/docker/immich/db/pg_dumpall.sql.tmp; then
|
||||
mv /opt/argento/docker/immich/db/pg_dumpall.sql.tmp /opt/argento/docker/immich/db/pg_dumpall.sql
|
||||
else
|
||||
rm -f /opt/argento/docker/immich/db/pg_dumpall.sql.tmp
|
||||
FAILURES+=("immich pg_dump")
|
||||
fi
|
||||
|
||||
# Dump Gitea SQLite for consistency
|
||||
sqlite3 /opt/argento/docker/gitea/data/gitea/gitea.db \
|
||||
".backup /opt/argento/docker/gitea/data/gitea/gitea.db.bak" \
|
||||
|
||||
Reference in New Issue
Block a user