Spaces:
Sleeping
Sleeping
Add application file
Browse files- Dockerfile +6 -2
Dockerfile
CHANGED
@@ -4,7 +4,11 @@ RUN useradd -m -u 1000 user
|
|
4 |
USER user
|
5 |
ENV PATH="/home/user/.local/bin:$PATH"
|
6 |
|
7 |
-
|
|
|
|
|
|
|
|
|
8 |
|
9 |
RUN pip install --no-cache-dir --upgrade -r requirements.txt
|
10 |
|
@@ -12,5 +16,5 @@ RUN pip install --no-cache-dir --upgrade -r requirements.txt
|
|
12 |
EXPOSE 7860
|
13 |
|
14 |
# CMD to run the FastAPI app with Uvicorn
|
15 |
-
CMD ["
|
16 |
|
|
|
4 |
USER user
|
5 |
ENV PATH="/home/user/.local/bin:$PATH"
|
6 |
|
7 |
+
WORKDIR /app
|
8 |
+
|
9 |
+
COPY --chown=user ./requirements.txt requirements.txt
|
10 |
+
|
11 |
+
COPY --chown=user . /app
|
12 |
|
13 |
RUN pip install --no-cache-dir --upgrade -r requirements.txt
|
14 |
|
|
|
16 |
EXPOSE 7860
|
17 |
|
18 |
# CMD to run the FastAPI app with Uvicorn
|
19 |
+
CMD ["uvicorn", "src.main:app", "--host", "0.0.0.0", "--port", "7860"]
|
20 |
|