Spaces:
Sleeping
Sleeping
File size: 1,076 Bytes
2b86483 7892e5f 2b86483 f5e0f08 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 | # Base Image
FROM python:3.11-slim
# Set environment variables
ENV PYTHONDONTWRITEBYTECODE=1
ENV PYTHONUNBUFFERED=1
ENV DEBIAN_FRONTEND=noninteractive
# Install System Dependencies
RUN apt-get update && apt-get install -y --no-install-recommends \
build-essential \
libcairo2-dev \
libpango1.0-dev \
libglib2.0-dev \
ffmpeg \
pkg-config \
# LaTeX packages
texlive-latex-base \
texlive-latex-extra \
texlive-fonts-recommended \
texlive-fonts-extra \
texlive-science \
texlive-latex-recommended \
latexmk \
# Required for dvi to svg/png conversion
dvisvgm \
dvipng \
# Additional tools
cm-super \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*
# Work Directory
WORKDIR /app
# Install Python Dependencies
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
# Copy App
COPY . .
# Expose Streamlit Port
EXPOSE 7860
# Run App
CMD sh -c "streamlit run app.py --server.port=${PORT:-7860} --server.address=0.0.0.0 --server.headless=true --server.fileWatcherType=none"
|