2025-05-11 14:06:58 +02:00
|
|
|
FROM alpine:latest
|
|
|
|
|
|
|
|
# https://docs.docker.com/reference/dockerfile/#environment-replacement
|
|
|
|
ENV DEBMIRRORURL="https://www.debian.org/mirror/list"
|
|
|
|
|
|
|
|
RUN apk update && \
|
|
|
|
apk add python3 py3-pip git
|
|
|
|
# inotify-tools
|
|
|
|
|
2025-05-11 15:08:26 +02:00
|
|
|
RUN mkdir /etc/debmirror && \
|
|
|
|
touch /etc/debmirror/MirrorListV6 && \
|
|
|
|
touch /etc/debmirror/MirrorListV4
|
2025-05-11 14:06:58 +02:00
|
|
|
WORKDIR /etc/debmirror/
|
|
|
|
|
2025-05-11 15:08:26 +02:00
|
|
|
COPY mainDocker.py /etc/debmirror/
|
|
|
|
COPY whatDomain.py /etc/debmirror/
|
|
|
|
COPY requirements.txt /etc/debmirror/
|
2025-05-11 14:06:58 +02:00
|
|
|
|
|
|
|
RUN python3 -m venv venv && \
|
|
|
|
venv/bin/python3 -m pip install --upgrade pip && \
|
|
|
|
venv/bin/pip3 install -r requirements.txt
|
|
|
|
|
2025-05-11 15:08:26 +02:00
|
|
|
COPY cron-jobs /etc/crontabs/
|
|
|
|
COPY gitPush.sh /etc/crontabs/
|
2025-05-11 14:06:58 +02:00
|
|
|
|
|
|
|
RUN chmod +x /etc/crontabs/gitPush.sh
|
|
|
|
|
|
|
|
CMD ["/usr/sbin/crond"]
|