Spaces:
Runtime error
Runtime error
Adds suggested working Docker
Browse files- Dockerfile +19 -3
Dockerfile
CHANGED
@@ -1,8 +1,24 @@
|
|
1 |
FROM python:3.8.9
|
2 |
-
|
3 |
WORKDIR /app
|
4 |
-
|
5 |
-
|
|
|
|
|
|
|
|
|
6 |
RUN pip3 install --no-cache-dir streamlit==1.10.0
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
7 |
EXPOSE 8501
|
8 |
CMD streamlit run app.py
|
|
|
1 |
FROM python:3.8.9
|
2 |
+
|
3 |
WORKDIR /app
|
4 |
+
|
5 |
+
COPY ./requirements.txt /app/requirements.txt
|
6 |
+
COPY ./packages.txt /app/packages.txt
|
7 |
+
|
8 |
+
RUN apt-get update && xargs -r -a /app/packages.txt apt-get install -y && rm -rf /var/lib/apt/lists/*
|
9 |
+
RUN pip3 install --no-cache-dir -r /app/requirements.txt
|
10 |
RUN pip3 install --no-cache-dir streamlit==1.10.0
|
11 |
+
|
12 |
+
# User
|
13 |
+
RUN useradd -m -u 1000 user
|
14 |
+
USER user
|
15 |
+
ENV HOME /home/user
|
16 |
+
ENV PATH $HOME/.local/bin:$PATH
|
17 |
+
|
18 |
+
WORKDIR $HOME
|
19 |
+
RUN mkdir app
|
20 |
+
WORKDIR $HOME/app
|
21 |
+
COPY . $HOME/app
|
22 |
+
|
23 |
EXPOSE 8501
|
24 |
CMD streamlit run app.py
|