2023-05-02 21:24:48 +03:00
|
|
|
FROM python:3.11 as builder
|
|
|
|
|
|
|
|
WORKDIR /usr/app
|
|
|
|
ENV PATH="/usr/app/venv/bin:$PATH"
|
2023-04-28 12:13:51 +03:00
|
|
|
|
2023-05-05 14:32:21 +03:00
|
|
|
RUN apt-get update && apt-get install -y --no-install-recommends ffmpeg && rm -rf /var/lib/apt/lists/*
|
2023-05-05 01:36:17 +03:00
|
|
|
|
2023-05-02 21:24:48 +03:00
|
|
|
RUN mkdir -p /usr/app
|
|
|
|
RUN python -m venv ./venv
|
|
|
|
|
|
|
|
COPY requirements.txt .
|
2023-04-28 12:13:51 +03:00
|
|
|
|
2023-05-02 21:24:48 +03:00
|
|
|
RUN pip install -r requirements.txt
|
2023-04-28 12:13:51 +03:00
|
|
|
|
|
|
|
# RUN pip config set global.index-url https://mirrors.aliyun.com/pypi/simple/
|
|
|
|
# RUN pip config set global.trusted-host mirrors.aliyun.com
|
|
|
|
|
2023-05-04 10:09:10 +03:00
|
|
|
FROM python:3.11
|
2023-04-28 12:13:51 +03:00
|
|
|
|
2023-05-02 21:24:48 +03:00
|
|
|
WORKDIR /usr/app
|
|
|
|
ENV PATH="/usr/app/venv/bin:$PATH"
|
|
|
|
|
|
|
|
COPY --from=builder /usr/app/venv ./venv
|
|
|
|
COPY . .
|
|
|
|
|
|
|
|
RUN cp ./gui/streamlit_app.py .
|
2023-04-28 12:13:51 +03:00
|
|
|
|
|
|
|
CMD ["streamlit", "run", "streamlit_app.py"]
|
2023-05-02 21:24:48 +03:00
|
|
|
|
|
|
|
EXPOSE 8501
|