diff --git a/localhost/caskd/daemons/cron/Containerfile b/localhost/caskd/daemons/cron/Containerfile new file mode 100644 index 0000000..efef896 --- /dev/null +++ b/localhost/caskd/daemons/cron/Containerfile @@ -0,0 +1,5 @@ +FROM alpine + +RUN mkdir -p /var/spool/cron /etc/crontabs + +CMD ["busybox", "crond", "-f", "-d", "8"] diff --git a/localhost/caskd/daemons/dcron/Containerfile b/localhost/caskd/daemons/dcron/Containerfile deleted file mode 100644 index d99f9a1..0000000 --- a/localhost/caskd/daemons/dcron/Containerfile +++ /dev/null @@ -1,7 +0,0 @@ -FROM alpine - -RUN --network=host apk add dcron - -RUN mkdir -p /var/spool/cron /etc/crontabs - -CMD ["/usr/sbin/crond", "-fP", "-L", "/dev/stderr"] diff --git a/localhost/caskd/scheduled/alpine-rsync/Containerfile b/localhost/caskd/scheduled/alpine-rsync/Containerfile index c235d5e..5ebb047 100644 --- a/localhost/caskd/scheduled/alpine-rsync/Containerfile +++ b/localhost/caskd/scheduled/alpine-rsync/Containerfile @@ -1,5 +1,6 @@ -FROM localhost/caskd/daemons/dcron:latest +FROM localhost/caskd/daemons/cron:latest RUN --network=host apk add rsync -ADD cron /etc/crontabs/root +RUN echo "0 * * * * /usr/libexec/alpine-rsync" > /etc/crontabs/root +ADD cron /usr/libexec/alpine-rsync diff --git a/localhost/caskd/scheduled/alpine-rsync/cron b/localhost/caskd/scheduled/alpine-rsync/cron old mode 100644 new mode 100755 index 5af8f52..299e57e --- a/localhost/caskd/scheduled/alpine-rsync/cron +++ b/localhost/caskd/scheduled/alpine-rsync/cron @@ -6,5 +6,7 @@ rsync \ --delay-updates \ --delete-delay \ --timeout=600 \ - rsync://rsync.alpinelinux.org/alpine/ \ + rsync://'[2604:1380:4601:dc00::1]'/alpine/ \ /run/repo/ + +# TODO: Use rsync://rsync.alpinelinux.org/alpine/ when they get anycast v6 diff --git a/localhost/config.mk b/localhost/config.mk index 981104f..562eeaf 100644 --- a/localhost/config.mk +++ b/localhost/config.mk @@ -1,5 +1,6 @@ localhost/caskd/scheduled/alpine-rsync/${BUILD_ID_OUT}: \ - localhost/caskd/daemons/dcron/${BUILD_ID_OUT} + localhost/caskd/scheduled/alpine-rsync/cron \ + localhost/caskd/daemons/cron/${BUILD_ID_OUT} # Wine WINEDEPS := localhost/caskd/archlinux/wine/${BUILD_ID_OUT}