1.2 KiB


Runs the debmirror utility and cron under docker.


  • Mount the data volume at /data. Packages and other data will be kept here. Packages & indexes will be kept in the files subdirectory.
  • Set any of the below options as environment variables in the container to further configure the mirror.


These environment variables configure the mirror and container. Defaults are shown

  • MIRROR_UID=1000 - filesystem uid for mirrored files
  • MIRROR_GID=1000 - filesystem gid for mirrored files
  • MIRROR_ARCH=amd64 - architectures to mirror
  • MIRROR_SECTION=main,restricted,universe,multiverse - sections to mirror
  • MIRROR_RELEASE=jammy,jammy-security,jammy-updates,jammy-backports - releases to mirror
  • - mirroring source server
  • MIRROR_PROTO=http - mirring protocol
  • MIRROR_CRON="8 4 * * *" - cron expression for mirroring job

Run it manually

docker exec -it <container> bash -c "time sudo -Hu aptmirror bash -c '. /tmp/; /usr/local/bin/'"


  • Have the container kill itself if the cronjob fails?