more docker changes
This commit is contained in:
@@ -14,6 +14,10 @@ RUN useradd -m -u 1000 celery
|
||||
# Set working directory
|
||||
WORKDIR /app
|
||||
|
||||
# Copy start.sh first and set permissions
|
||||
COPY start.sh .
|
||||
RUN chmod +x start.sh
|
||||
|
||||
# Copy requirements first to leverage Docker cache
|
||||
COPY requirements.txt .
|
||||
RUN pip install --no-cache-dir -r requirements.txt
|
||||
@@ -23,11 +27,10 @@ COPY . .
|
||||
|
||||
# Create necessary directories and set permissions
|
||||
RUN mkdir -p /app/uploads /app/static/uploads && \
|
||||
chown -R celery:celery /app && \
|
||||
chmod +x /app/start.sh
|
||||
chown -R celery:celery /app
|
||||
|
||||
# Switch to non-root user
|
||||
USER celery
|
||||
|
||||
# Set entrypoint
|
||||
ENTRYPOINT ["/app/start.sh"]
|
||||
ENTRYPOINT ["./start.sh"]
|
||||
Reference in New Issue
Block a user