mwitiderrick commited on
Commit
f8ea4a7
·
verified ·
1 Parent(s): c774a7d

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +10 -17
Dockerfile CHANGED
@@ -1,18 +1,11 @@
1
- # Hugging Face Spaces Chainlit template
2
- FROM python:3.11-slim
3
-
4
- # Set working directory
5
- WORKDIR /app
6
-
7
- # Install Python deps
8
- COPY requirements.txt .
9
- RUN pip install --upgrade pip && pip install -r requirements.txt
10
-
11
- # Copy source
12
  COPY . .
13
-
14
- # Expose Chainlit port
15
- EXPOSE 7860
16
-
17
- # Launch Chainlit app
18
- CMD ["chainlit", "run", "app.py"]
 
1
+ FROM python:3.11
2
+ RUN useradd -m -u 1000 user
3
+ USER user
4
+ ENV HOME=/home/user \
5
+ PATH=/home/user/.local/bin:$PATH
6
+ WORKDIR $HOME/app
7
+ COPY --chown=user . $HOME/app
8
+ COPY ./requirements.txt ~/app/requirements.txt
9
+ RUN pip install -r requirements.txt
 
 
10
  COPY . .
11
+ CMD ["chainlit", "run", "app.py", "--port", "7860", "-h"]