1 Offline Repository Mirrors
2 ==========================
4 Offline repository mirrors are pointing to APT repositories, for example from Proxmox VE, Proxmox
5 Backup Server or Debian. After the initial setup, you can mirror all the available packages locally.
6 They are organized by creating point-in-time snapshots of the repositories. Those snapshots can then
7 be exported to a configured medium.
12 First, either run the ``setup`` wizard (``proxmox-offline-mirror setup``), or the
13 ``config mirror add`` command.
15 .. tip:: The quickest way to set up all relevant repositories for a Proxmox solution is to use the
16 ``setup`` wizard. Choose the product when adding a mirror and confirm the question regarding
17 auto-adding the Debian base repos.
19 For example, to manually add a mirror entry for the Debian Bullseye security repository, the
20 following command can be used:
22 .. code-block:: console
24 proxmox-offline-mirror config mirror add \
25 --id debian-bullseye-security \
26 --architectures amd64 \
28 --repository 'deb http://deb.debian.org/debian-security bullseye-security main contrib non-free' \
29 --key-path /etc/apt/trusted.gpg.d/debian-archive-bullseye-security-automatic.gpg \
32 --dir /path/to/mirror/dir/debian-bullseye-security
34 .. note:: The `all` architecture is meant for architecture independent packages, not for all
35 possible architectures. It is usually always sensible to add it in addition to the host-specific
41 To create the first (and subsequent) snapshots, the following command can be used:
43 .. code-block:: console
45 proxmox-offline-mirror mirror snapshot create debian-bullseye-security
47 .. note:: Depending on the parameters used and the size of the original repository, creating a
48 snapshot can take both time and require significant disk space. This is especially true for the
49 initial snapshot, as subsequent ones will re-use unchanged package files and indices.
54 After removing a snapshot with ``proxmox-offline-mirror mirror snapshot remove``, a
55 ``proxmox-offline-mirror mirror gc`` invocation is needed to trigger the garbage collection to
56 actually remove any contents from the underlying hard link pool that are no longer needed.