sarthaksavvy commited on
Commit
10a75b8
·
1 Parent(s): 4ac25fc
Files changed (1) hide show
  1. Dockerfile +9 -11
Dockerfile CHANGED
@@ -1,23 +1,21 @@
1
  FROM python:3.10-slim
2
 
3
- WORKDIR /app
4
-
5
- RUN pip install --upgrade pip
6
- RUN pip install fastapi uvicorn transformers
7
- RUN pip install h5py --only-binary h5py
8
- RUN pip install tensorflow tf-keras torch torchvision
9
-
10
  RUN useradd user
11
  # Switch to the "user" user
12
  USER user
13
 
14
- # ENV HOME=/home/user \
15
- # PATH=/home/user/.local/bin:$PATH
16
 
17
  # Set the working directory to the user's home directory
18
- # WORKDIR $HOME/app
19
 
20
  # Copy the current directory contents into the container at $HOME/app setting the owner to the user
21
- COPY --chown=user . /app
 
 
 
 
 
22
 
23
  CMD fastapi run --reload --host=0.0.0.0 --port=7860
 
1
  FROM python:3.10-slim
2
 
 
 
 
 
 
 
 
3
  RUN useradd user
4
  # Switch to the "user" user
5
  USER user
6
 
7
+ ENV HOME=/home/user \
8
+ PATH=/home/user/.local/bin:$PATH
9
 
10
  # Set the working directory to the user's home directory
11
+ WORKDIR $HOME/app
12
 
13
  # Copy the current directory contents into the container at $HOME/app setting the owner to the user
14
+ COPY --chown=user . $HOME/app
15
+
16
+ RUN pip install --upgrade pip
17
+ RUN pip install fastapi uvicorn transformers
18
+ RUN pip install h5py --only-binary h5py
19
+ RUN pip install tensorflow tf-keras torch torchvision
20
 
21
  CMD fastapi run --reload --host=0.0.0.0 --port=7860