Spaces:
Sleeping
Sleeping
Update Dockerfile
Browse files- Dockerfile +12 -18
Dockerfile
CHANGED
@@ -1,23 +1,17 @@
|
|
1 |
-
|
2 |
-
FROM python:3.10-slim
|
3 |
|
4 |
-
#
|
5 |
-
|
6 |
-
|
7 |
-
# Install necessary system dependencies
|
8 |
-
RUN apt-get update && \
|
9 |
-
apt-get install -y libopencv-dev tesseract-ocr && \
|
10 |
-
rm -rf /var/lib/apt/lists/*
|
11 |
|
12 |
-
#
|
13 |
-
COPY requirements.txt /app/
|
14 |
-
RUN pip install
|
15 |
|
16 |
-
#
|
17 |
-
|
18 |
|
19 |
-
#
|
20 |
-
|
21 |
|
22 |
-
# Command to run
|
23 |
-
CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "
|
|
|
1 |
+
FROM python:3.10
|
|
|
2 |
|
3 |
+
# Install tesseract and dependencies
|
4 |
+
RUN apt-get update && apt-get install -y tesseract-ocr
|
|
|
|
|
|
|
|
|
|
|
5 |
|
6 |
+
# Install Python dependencies
|
7 |
+
COPY requirements.txt /app/requirements.txt
|
8 |
+
RUN pip install -r /app/requirements.txt
|
9 |
|
10 |
+
# Set the working directory
|
11 |
+
WORKDIR /app
|
12 |
|
13 |
+
# Copy the rest of your application code
|
14 |
+
COPY . /app
|
15 |
|
16 |
+
# Command to run your FastAPI app
|
17 |
+
CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "8080"]
|