File size: 673 Bytes
6862690
 
 
 
 
 
 
 
 
 
 
 
f64d1b3
6862690
 
 
 
 
ec60126
6862690
ec60126
6862690
ec60126
4cd1ad2
06643fb
 
ec60126
68787b5
06643fb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
FROM nvidia/cuda:11.7.1-devel-ubuntu22.04

RUN apt-get update -y
RUN apt-get install -y sudo wget curl nano git \
    python3 python3-pip && rm -rf /var/lib/apt/lists/*

# Create a group and user
ENV APPUSER="appuser"
ENV HOME=/home/$APPUSER
RUN groupadd -g 999 appgroup && \
    useradd -r -u 999 -g appgroup $APPUSER

USER $APPUSER
WORKDIR $HOME

RUN pip install --user streamlit==1.28

ENV PATH="$HOME/.local/bin:$PATH"

COPY --chown=$APPUSER:appgroup . $HOME/app

WORKDIR $HOME/app

# Expose port for streamlit
ENV PORT=8501
EXPOSE $PORT

# Run streamlit app under conda environment
CMD ["sh", "-c", "streamlit run --server.port=$PORT --server.address=0.0.0.0 app.py"]