Ani14 commited on
Commit
bbfb7c5
·
verified ·
1 Parent(s): fbdacde

Upload Dockerfile.dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile.dockerfile +28 -0
Dockerfile.dockerfile ADDED
@@ -0,0 +1,28 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Use an official Python runtime as a parent image
2
+ FROM python:3.9-slim
3
+
4
+ # Set the working directory
5
+ WORKDIR /app
6
+
7
+ # Install system dependencies
8
+ RUN apt-get update && apt-get install -y \
9
+ libgl1-mesa-glx \
10
+ libglib2.0-0 \
11
+ tesseract-ocr \
12
+ tesseract-ocr-eng \
13
+ && rm -rf /var/lib/apt/lists/*
14
+
15
+ # Copy the requirements file into the container
16
+ COPY requirements.txt .
17
+
18
+ # Install Python dependencies
19
+ RUN pip install --no-cache-dir -r requirements.txt
20
+
21
+ # Copy the rest of the application code into the container
22
+ COPY . .
23
+
24
+ # Make port 8000 available to the world outside this container
25
+ EXPOSE 8000
26
+
27
+ # Run the application
28
+ CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "7860"]