zhenxun_bot/Dockerfile

29 lines
550 B
Docker
Raw Normal View History

2024-08-14 13:35:03 +08:00
FROM python:3.11-slim-bookworm
EXPOSE 8080
WORKDIR /app/zhenxun
COPY . /app/zhenxun
2024-09-02 23:12:27 +08:00
RUN apt update && \
apt upgrade -y && \
apt install -y --no-install-recommends \
gcc \
g++ && \
apt clean
2024-08-14 13:35:03 +08:00
RUN pip install poetry -i https://mirrors.aliyun.com/pypi/simple/
RUN poetry install
VOLUME /app/zhenxun/data /app/zhenxun/data
VOLUME /app/zhenxun/resources /app/zhenxun/resources
2024-09-02 23:12:27 +08:00
VOLUME /app/zhenxun/.env.dev /app/zhenxun/.env.dev
2024-08-14 13:35:03 +08:00
RUN poetry run playwright install --with-deps chromium
2024-09-02 23:12:27 +08:00
CMD ["poetry", "run", "python", "bot.py"]