Spaces:
Sleeping
Sleeping
maslionok
commited on
Commit
·
aaec47f
1
Parent(s):
3831088
fix
Browse files- Dockerfile +18 -5
Dockerfile
CHANGED
@@ -1,13 +1,26 @@
|
|
1 |
FROM python:3.11-slim
|
2 |
|
3 |
-
|
4 |
|
5 |
-
|
6 |
|
7 |
-
|
|
|
|
|
|
|
|
|
8 |
|
9 |
-
|
|
|
10 |
|
11 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
12 |
|
13 |
CMD ["python", "app.py"]
|
|
|
1 |
FROM python:3.11-slim
|
2 |
|
3 |
+
ENV XDG_CACHE_HOME=/tmp/.cache
|
4 |
|
5 |
+
WORKDIR /app
|
6 |
|
7 |
+
# Install dependencies
|
8 |
+
RUN apt-get update && apt-get install -y --no-install-recommends \
|
9 |
+
build-essential \
|
10 |
+
curl \
|
11 |
+
&& rm -rf /var/lib/apt/lists/*
|
12 |
|
13 |
+
# Create cache directory and set permissions
|
14 |
+
RUN mkdir -p /tmp/.cache/huggingface && chmod -R 777 /tmp/.cache
|
15 |
|
16 |
+
# Copy app files
|
17 |
+
COPY . .
|
18 |
+
|
19 |
+
# Upgrade pip and install packages
|
20 |
+
RUN pip install --upgrade pip
|
21 |
+
RUN pip install "impresso_pipelines[ocrqa]==0.4.6.6"
|
22 |
+
RUN pip install gradio
|
23 |
+
|
24 |
+
EXPOSE 7860
|
25 |
|
26 |
CMD ["python", "app.py"]
|