feat: schedule with busybox crond instead of supercronic

Same scheduler qbit-maid uses: entrypoint.sh writes the crontab and execs
crond -f. Drops the supercronic package from the image.

- crontab lives in /tmp/crontabs because the rootfs is read-only
- MAILTO= keeps job output on crond's stdout/stderr (container log), which
  is what supercronic -passthrough-logs provided
- busybox crond only loads crontab files owned by uid 0 and calls
  initgroups() per job, so the container needs root + CAP_SETGID; the
  entrypoint now fails fast (exit 78) when it is not root
- no @reboot job: a container restart must not start a backup
This commit is contained in:
trex Bot committed 2026-11-24 22:24:29 -06:00
1 parent 313db934e4
commit ce825c7526
3 files changed
+40 -8

No files matched your search

+1 -2
View File
@@ -3,12 +3,11 @@ FROM python:3.13-alpine
# mariadb-client -> mariadb-dump
# restic -> the backup engine
# docker-cli -> only used when COLD_BACKUP=true (docker exec into seafile)
# supercronic -> cron with passthrough logs
# busybox crond -> the scheduler (ships with the base image, no extra package)
RUN apk add --no-cache \
mariadb-client \
restic \
docker-cli \
supercronic \
tzdata \
&& adduser -u 99 -D -G users -h /config -s /sbin/nologin backup