Initial commit
This commit is contained in:
commit
983cee0320
322 changed files with 57174 additions and 0 deletions
26
backup/first -fina app/Dockerfile
Executable file
26
backup/first -fina app/Dockerfile
Executable file
|
|
@ -0,0 +1,26 @@
|
|||
FROM python:3.11-slim
|
||||
|
||||
# Install Tesseract OCR
|
||||
RUN apt-get update && \
|
||||
apt-get install -y tesseract-ocr tesseract-ocr-eng && \
|
||||
rm -rf /var/lib/apt/lists/*
|
||||
|
||||
RUN useradd -m -u 1000 appuser
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
COPY requirements.txt .
|
||||
RUN pip install --no-cache-dir -r requirements.txt
|
||||
|
||||
COPY --chown=appuser:appuser . .
|
||||
|
||||
# Create instance directory with proper permissions
|
||||
RUN mkdir -p /app/instance /app/app/static/uploads && \
|
||||
chown -R appuser:appuser /app && \
|
||||
chmod 755 /app/instance
|
||||
|
||||
USER appuser
|
||||
|
||||
EXPOSE 5000
|
||||
|
||||
CMD ["gunicorn", "--bind", "0.0.0.0:5000", "--workers", "2", "--timeout", "120", "wsgi:app"]
|
||||
Loading…
Add table
Add a link
Reference in a new issue