From 7f0e9525da5a113925083bcd3d11cab6863a2597 Mon Sep 17 00:00:00 2001 From: sunba91-su Date: Mon, 8 Jun 2026 19:12:29 +0330 Subject: [PATCH] fix: ensure /data volume is writable by non-root appuser The Dockerfile runs as non-root appuser (UID 1001) but /data in the image is owned by root. When a named volume mounts at /data, it inherits root ownership, causing 'permission denied' when SQLite tries to create standup-bot.db. Fix: add RUN mkdir -p /data && chown -R appuser:appuser /data before the USER appuser directive. Closes #31 --- Dockerfile | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Dockerfile b/Dockerfile index 63a206e..3554b08 100644 --- a/Dockerfile +++ b/Dockerfile @@ -23,6 +23,8 @@ RUN apk add --no-cache ca-certificates tzdata && \ COPY --from=builder /bin/bot /bot +RUN mkdir -p /data && chown -R appuser:appuser /data + USER appuser WORKDIR /home/appuser VOLUME /data