-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
29 lines (27 loc) · 680 Bytes
/
Dockerfile
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
FROM python:3.12.5-slim-bookworm AS build
WORKDIR /src
COPY leek/ ./leek
COPY pyproject.toml .
COPY setup.py .
RUN <<EOF
python -m pip install -U pip build
python -m build
EOF
FROM python:3.12.5-slim-bookworm
LABEL "org.opencontainers.image.source"="https://github.com/justalemon/Leek"
WORKDIR /dist
COPY --from=build src/dist /dist
RUN <<EOF
python -m pip install -U pip
python -m pip install --find-links /dist/ leekbot[extras]
apt-get update
apt-get upgrade
python -m playwright install-deps
python -m playwright install firefox
python -m pip cache purge
apt-get clean
rm -rf /var/cache/apt/archives
rm -rf /var/lib/apt/lists/*
rm -rf /dist
EOF
CMD ["python", "-m", "leek"]