Ali2206 commited on
Commit
3a08b41
·
verified ·
1 Parent(s): 770d5fe

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +20 -0
Dockerfile CHANGED
@@ -1,11 +1,31 @@
 
1
  FROM python:3.10
2
 
 
3
  WORKDIR /app
4
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
5
  COPY requirements.txt .
6
  RUN pip install --no-cache-dir -r requirements.txt
7
 
 
8
  COPY . .
9
 
 
10
  EXPOSE 7860
 
 
11
  CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "7860"]
 
1
+ # Use official Python image
2
  FROM python:3.10
3
 
4
+ # Set working directory
5
  WORKDIR /app
6
 
7
+ # Install system packages (LaTeX, fonts, and compiler tools)
8
+ RUN apt-get update && apt-get install -y \
9
+ latexmk \
10
+ texlive-latex-recommended \
11
+ texlive-fonts-recommended \
12
+ texlive-latex-extra \
13
+ texlive-xetex \
14
+ lmodern \
15
+ fontconfig \
16
+ build-essential \
17
+ && apt-get clean \
18
+ && rm -rf /var/lib/apt/lists/*
19
+
20
+ # Install Python dependencies
21
  COPY requirements.txt .
22
  RUN pip install --no-cache-dir -r requirements.txt
23
 
24
+ # Copy app code
25
  COPY . .
26
 
27
+ # Expose FastAPI port
28
  EXPOSE 7860
29
+
30
+ # Start FastAPI app
31
  CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "7860"]