wip
This commit is contained in:
parent
78ce15e82d
commit
0a31714a93
10 changed files with 159 additions and 149 deletions
13
Dockerfile
13
Dockerfile
|
@ -20,20 +20,19 @@ RUN pip install --upgrade pip && \
|
|||
COPY . .
|
||||
|
||||
# Create the instance directory for SQLite
|
||||
RUN mkdir -p instance && \
|
||||
chmod 777 instance
|
||||
# RUN mkdir -p instance && \
|
||||
# chmod 777 instance
|
||||
|
||||
# Create a non-root user to run the app
|
||||
RUN useradd -m appuser && \
|
||||
chown -R appuser:appuser /app
|
||||
# RUN useradd -m appuser && \
|
||||
# chown -R appuser:appuser /app
|
||||
|
||||
USER appuser
|
||||
# USER appuser
|
||||
|
||||
# Set environment variables
|
||||
ENV PYTHONDONTWRITEBYTECODE=1 \
|
||||
PYTHONUNBUFFERED=1 \
|
||||
SECRET_KEY="" \
|
||||
FLASK_APP=wsgi.py
|
||||
|
||||
# Run gunicorn
|
||||
CMD ["gunicorn", "--bind", "0.0.0.0:8000", "--timeout", "120", "--workers", "4", "wsgi:app"]
|
||||
CMD ["gunicorn", "--bind", "0.0.0.0:8000", "--timeout", "120", "--workers", "4", "run:app"]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue