Ausbel commited on
Commit
0c9a874
1 Parent(s): 1323d69

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +18 -2
Dockerfile CHANGED
@@ -1,17 +1,33 @@
 
 
 
 
1
  WORKDIR /code
2
 
 
 
3
  COPY ./requirements.txt /code/requirements.txt
4
 
 
 
5
  RUN pip install --no-cache-dir --upgrade -r /code/requirements.txt
6
 
 
 
7
  # Copy the model to the container
8
  COPY XGB.joblib .
9
 
 
 
10
  # Copy the FastAPI app code to the container
11
- COPY main.py . # Expose the port the FastAPI app will run on
 
 
12
 
 
13
  EXPOSE 7860
14
 
 
 
15
  # The CMD instruction specifies the command to run when the container starts
16
  CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "7860"]
17
-
 
1
+ FROM python:3.9
2
+
3
+
4
+
5
  WORKDIR /code
6
 
7
+
8
+
9
  COPY ./requirements.txt /code/requirements.txt
10
 
11
+
12
+
13
  RUN pip install --no-cache-dir --upgrade -r /code/requirements.txt
14
 
15
+
16
+
17
  # Copy the model to the container
18
  COPY XGB.joblib .
19
 
20
+
21
+
22
  # Copy the FastAPI app code to the container
23
+ COPY main.py .
24
+
25
+
26
 
27
+ # Expose the port the FastAPI app will run on
28
  EXPOSE 7860
29
 
30
+
31
+
32
  # The CMD instruction specifies the command to run when the container starts
33
  CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "7860"]