Rehan12345678 commited on
Commit
eb64a08
·
verified ·
1 Parent(s): 5adba13

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +6 -4
Dockerfile CHANGED
@@ -7,11 +7,13 @@ WORKDIR /code
7
  # Copy the requirements file into the container
8
  COPY ./requirements.txt /code/requirements.txt
9
 
10
- # Install the dependencies from the requirements.txt file
11
  RUN pip install --no-cache-dir --upgrade -r /code/requirements.txt
12
 
13
- # Copy the rest of your application code into the container
14
  COPY ./ /code/
15
 
16
- # Run the FastAPI app with Uvicorn, listening on the required port
17
- CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "7860"]
 
 
 
7
  # Copy the requirements file into the container
8
  COPY ./requirements.txt /code/requirements.txt
9
 
10
+ # Install the dependencies
11
  RUN pip install --no-cache-dir --upgrade -r /code/requirements.txt
12
 
13
+ # Copy your entire project (including the src folder) into the container
14
  COPY ./ /code/
15
 
16
+ # Run the FastAPI app, specifying the module path
17
+ # The format is <folder.file_name>:<app_variable>
18
+ # If you have a src folder and streamlit_app.py file, the path is src.streamlit_app
19
+ CMD ["uvicorn", "src.streamlit_app:app", "--host", "0.0.0.0", "--port", "7860"]