nextcloud: move redis volume to VOL_CACHE

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
code
2026-10-01 18:37:56 +00:00
co-authored by Claude Opus 5.5
parent cad7beb975
commit 930e95a52a
3 changed files with 4 additions and 4 deletions
+2 -2
View File
@@ -41,12 +41,12 @@ To test without NPM, open http://HOST_IP:8084. Set `NEXTCLOUD_DOMAIN=HOST_IP` an
## Volume Notes ## Volume Notes
/var/lib/mysql – host path /data/nextcloud/db (MariaDB data) /var/lib/mysql – host path /data/nextcloud/db (MariaDB data)
/data – host path /data/nextcloud/redis (Redis cache, safe to lose) /data – host path /var/cache/nextcloud/redis (Redis cache, file locks and sessions; safe to lose, users are logged out)
/var/www/html – host path /data/nextcloud/data (Nextcloud app, config and user files; shared by nextcloud and nextcloud-cron) /var/www/html – host path /data/nextcloud/data (Nextcloud app, config and user files; shared by nextcloud and nextcloud-cron)
/var/www/html/data/appdata_<instanceid>/preview – host path /var/cache/nextcloud/preview (generated thumbnails; only once NEXTCLOUD_PREVIEW_DIR is set) /var/www/html/data/appdata_<instanceid>/preview – host path /var/cache/nextcloud/preview (generated thumbnails; only once NEXTCLOUD_PREVIEW_DIR is set)
Back up `/data/nextcloud/data` and `/data/nextcloud/db` together. Leave out `/var/cache`: previews are regenerated on demand. Back up `/data/nextcloud/data` and `/data/nextcloud/db` together. Leave out `/var/cache`: previews are regenerated on demand, and Redis rebuilds its cache.
### Moving previews to VOL_CACHE ### Moving previews to VOL_CACHE
+1 -1
View File
@@ -18,7 +18,7 @@ services:
image: ${REDIS_IMAGE:-redis:alpine} image: ${REDIS_IMAGE:-redis:alpine}
restart: ${REDIS_RESTART:-unless-stopped} restart: ${REDIS_RESTART:-unless-stopped}
volumes: volumes:
- ${VOL_PATH:-/data}/nextcloud/redis:/data - ${VOL_CACHE:-/var/cache}/nextcloud/redis:/data
networks: networks:
- internal - internal
+1 -1
View File
@@ -1,6 +1,6 @@
# Compose # Compose
VOL_PATH=/data VOL_PATH=/data
# Regenerable data (previews) — exclude from backups # Regenerable data (previews, redis) — exclude from backups
VOL_CACHE=/var/cache VOL_CACHE=/var/cache
NEXTCLOUD_IMAGE=nextcloud:35 NEXTCLOUD_IMAGE=nextcloud:35
NEXTCLOUD_RESTART=unless-stopped NEXTCLOUD_RESTART=unless-stopped