mirror of
https://github.com/nethunterzist/trendyol-analiz
synced 2026-07-01 01:17:04 +00:00
fix: resolve Permission denied for /data/reports in Coolify deployment
- Run container as root initially to fix volume mount permissions - Use gosu to drop to appuser before starting uvicorn - chown /data directories at startup (Coolify mounts volumes as root) Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -12,6 +12,7 @@ WORKDIR /app
|
||||
RUN apt-get update && apt-get install -y \
|
||||
libpq-dev \
|
||||
curl \
|
||||
gosu \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
|
||||
# Copy requirements first (Docker layer caching)
|
||||
@@ -38,7 +39,6 @@ RUN chmod +x startup.sh
|
||||
# Create non-root user for security
|
||||
RUN useradd -m -u 1001 appuser && \
|
||||
chown -R appuser:appuser /app /data
|
||||
USER appuser
|
||||
|
||||
# Expose backend port
|
||||
EXPOSE 8001
|
||||
|
||||
Reference in New Issue
Block a user