Praveen0309 commited on
Commit
94d02c9
·
1 Parent(s): fb83194
Files changed (1) hide show
  1. Dockerfile +4 -0
Dockerfile CHANGED
@@ -1,9 +1,13 @@
1
  FROM python:3.10
 
 
2
  WORKDIR /app
3
  ENV FLASK_APP=app.py
4
  ENV FLASK_RUN_HOST=0.0.0.0
5
  COPY requirements.txt requirements.txt
 
6
  RUN pip install -r requirements.txt
 
7
  EXPOSE 7860
8
  COPY . .
9
  CMD ["flask", "run"]
 
1
  FROM python:3.10
2
+ RUN useradd -m -u 1000 user
3
+ USER user
4
  WORKDIR /app
5
  ENV FLASK_APP=app.py
6
  ENV FLASK_RUN_HOST=0.0.0.0
7
  COPY requirements.txt requirements.txt
8
+ RUN chown -R user:user /code
9
  RUN pip install -r requirements.txt
10
+ COPY --chown=user:user . /app
11
  EXPOSE 7860
12
  COPY . .
13
  CMD ["flask", "run"]