Explain the ${VAR:-fallback} syntax where it is actually read
The line reads as if /srv were appended to whatever you set. Says so right above it now, and drops the comment block that repeated the mkdir instruction already in the header. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
1 parent
6dcb77fa73
commit
982de53c77
1 file changed
+4
-3
+4
-3
@@ -32,10 +32,11 @@ services:
|
||||
- MAX_VERSIONS_PER_NOTE=${MAX_VERSIONS_PER_NOTE:-}
|
||||
- VERSION_RETENTION_DAYS=${VERSION_RETENTION_DAYS:-}
|
||||
- VERSION_COALESCE_MINUTES=${VERSION_COALESCE_MINUTES:-}
|
||||
# Bind mounts, not named volumes: the data sits in a plain directory on the
|
||||
# Docker host, so whatever backs up the host also backs up InkNote.
|
||||
# Create it first: mkdir -p /srv/inknote/{db,uploads} && chown -R 1000:1000 /srv/inknote
|
||||
user: "${INKNOTE_UID:-1000}:${INKNOTE_GID:-1000}"
|
||||
# Bind mounts, so the data is a plain directory on the host.
|
||||
# ${VAR:-fallback} means "VAR, or fallback if VAR is empty" — one or the
|
||||
# other, never both. Set INKNOTE_DATA_DIR=/root/inknote and the paths below
|
||||
# are /root/inknote/db and /root/inknote/uploads; /srv is then never used.
|
||||
volumes:
|
||||
- ${INKNOTE_DATA_DIR:-/srv/inknote}/db:/app/data
|
||||
- ${INKNOTE_DATA_DIR:-/srv/inknote}/uploads:/app/uploads
|
||||
|
||||
Reference in new issue
Block a user