This commit is contained in:
blankhex committed 2026-10-16 01:06:20 +03:00
1 parent fd2e7f6cd8
commit 65534ecfd5
4 files changed
+20 -17

No files matched your search

+5 -5
View File
@@ -44,16 +44,16 @@ RUN chmod +x /app/server
COPY --from=builder /build/static /app/static
COPY --from=builder /build/templates /app/templates
# Ensure the app user owns the working dir (DB file created here at runtime)
# Ensure the app user owns the working dir
RUN chown -R app:app /app
# Create a dedicated subdirectory for persistable data (mounted as a volume)
RUN mkdir -p /app/data
# Create data directory owned by app user (for named volume mount)
RUN mkdir -p /data && chown app:app /data
USER app
# Expose the HTTP port
EXPOSE 8080
# Default command
CMD ["/app/server", "-addr", ":8080", "-db", "/app/data/state.db"]
# Default command (runs as 'app' user, DB stored in named volume)
CMD ["/app/server", "-addr", ":8080", "-db", "/data/state.db"]