Spaces:
Sleeping
Sleeping
Update Dockerfile
Browse files- Dockerfile +6 -5
Dockerfile
CHANGED
@@ -1,15 +1,16 @@
|
|
1 |
FROM python:3.11-slim
|
2 |
-
RUN pip install --no-cache-dir --upgrade pip
|
3 |
|
4 |
WORKDIR /app
|
5 |
COPY . .
|
6 |
|
7 |
-
#
|
8 |
-
RUN pip install --no-cache-dir .
|
9 |
-
|
10 |
-
# now install the rest of your requirements
|
11 |
RUN pip install --no-cache-dir -r requirements.txt
|
12 |
|
|
|
|
|
|
|
13 |
EXPOSE 5001
|
14 |
CMD ["uvicorn","main:app","--host","0.0.0.0","--port","5001"]
|
15 |
|
|
|
|
1 |
FROM python:3.11-slim
|
2 |
+
RUN pip install --no-cache-dir --upgrade pip
|
3 |
|
4 |
WORKDIR /app
|
5 |
COPY . .
|
6 |
|
7 |
+
# Install only what's on PyPI
|
|
|
|
|
|
|
8 |
RUN pip install --no-cache-dir -r requirements.txt
|
9 |
|
10 |
+
# Make src/ importable without installing
|
11 |
+
ENV PYTHONPATH=/app/src
|
12 |
+
|
13 |
EXPOSE 5001
|
14 |
CMD ["uvicorn","main:app","--host","0.0.0.0","--port","5001"]
|
15 |
|
16 |
+
|