Spaces:
Sleeping
Sleeping
Commit
·
02057bf
1
Parent(s):
51ab4b9
added expose port number
Browse files- Dockerfile +3 -3
Dockerfile
CHANGED
@@ -10,8 +10,6 @@ COPY ./requirements.txt /code/requirements.txt
|
|
10 |
# Install requirements.txt
|
11 |
RUN pip install --no-cache-dir --upgrade -r /code/requirements.txt
|
12 |
|
13 |
-
RUN pip install numpy --upgrade
|
14 |
-
|
15 |
# Set up a new user named "user" with user ID 1000
|
16 |
RUN useradd -m -u 1000 user
|
17 |
# Switch to the "user" user
|
@@ -25,6 +23,8 @@ WORKDIR $HOME/app
|
|
25 |
|
26 |
# Copy the current directory contents into the container at $HOME/app setting the owner to the user
|
27 |
COPY --chown=user . $HOME/app
|
28 |
-
|
|
|
|
|
29 |
# Start the FastAPI app on port 7860, the default port expected by Spaces
|
30 |
CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "7860"]
|
|
|
10 |
# Install requirements.txt
|
11 |
RUN pip install --no-cache-dir --upgrade -r /code/requirements.txt
|
12 |
|
|
|
|
|
13 |
# Set up a new user named "user" with user ID 1000
|
14 |
RUN useradd -m -u 1000 user
|
15 |
# Switch to the "user" user
|
|
|
23 |
|
24 |
# Copy the current directory contents into the container at $HOME/app setting the owner to the user
|
25 |
COPY --chown=user . $HOME/app
|
26 |
+
|
27 |
+
EXPOSE 7860
|
28 |
+
|
29 |
# Start the FastAPI app on port 7860, the default port expected by Spaces
|
30 |
CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "7860"]
|