Hetzner Aptitude Mirror

Last change on 2023-10-09 • Created on 2020-05-18 • ID: RO-385E4

IPv6

If your server is IPv6 capable, you can also access the mirror directly with IPv6. There are no necessary changes.

Debian 12 (bookworm)

In Debian 12, you can use the mirror by adding the following to the /etc/apt/sources.list file:

#Packages and Security Updates from the Hetzner Debian Mirror
deb https://mirror.hetzner.com/debian/packages  bookworm           main contrib non-free non-free-firmware
deb https://mirror.hetzner.com/debian/packages  bookworm-updates   main contrib non-free non-free-firmware
deb https://mirror.hetzner.com/debian/security  bookworm-security  main contrib non-free non-free-firmware
deb https://mirror.hetzner.com/debian/packages  bookworm-backports main contrib non-free non-free-firmware

It is recommended to always have a secondary one configured as well as the security repository.

deb http://deb.debian.org/debian               bookworm          main contrib non-free non-free-firmware
deb http://deb.debian.org/debian               bookworm-updates  main contrib non-free non-free-firmware
deb http://security.debian.org/debian-security bookworm-security main contrib non-free non-free-firmware

Debian 11 (bullseye)

In Debian 11, you can use the mirror by adding the following to the /etc/apt/sources.list file:

#Packages and Security Updates from the Hetzner Debian Mirror
deb https://mirror.hetzner.com/debian/packages  bullseye           main contrib non-free
deb https://mirror.hetzner.com/debian/packages  bullseye-updates   main contrib non-free
deb https://mirror.hetzner.com/debian/security  bullseye-security  main contrib non-free
deb https://mirror.hetzner.com/debian/packages  bullseye-backports main contrib non-free

It is recommended to always have a secondary one configured as well as the security repository.

deb http://deb.debian.org/debian               bullseye-updates  main contrib non-free
deb http://deb.debian.org/debian               bullseye          main contrib non-free
deb http://security.debian.org/debian-security bullseye-security main contrib non-free

Ubuntu 22.04 Jammy Jellyfish

In Ubuntu 22.04, you can use the mirror by adding the following to the /etc/apt/sources.list file:

# Packages and Updates from the Hetzner Ubuntu Mirror
deb http://mirror.hetzner.com/ubuntu/packages jammy           main restricted universe multiverse
deb http://mirror.hetzner.com/ubuntu/packages jammy-updates   main restricted universe multiverse
deb http://mirror.hetzner.com/ubuntu/packages jammy-backports main restricted universe multiverse
deb http://mirror.hetzner.com/ubuntu/packages jammy-security  main restricted universe multiverse

Ubuntu 20.04 Focal Fossa

In Ubuntu 20.04, you can use the mirror by adding the following to the /etc/apt/sources.list file:

# Packages and Updates from the Hetzner Ubuntu Mirror
deb http://mirror.hetzner.com/ubuntu/packages focal           main restricted universe multiverse
deb http://mirror.hetzner.com/ubuntu/packages focal-updates   main restricted universe multiverse
deb http://mirror.hetzner.com/ubuntu/packages focal-backports main restricted universe multiverse
deb http://mirror.hetzner.com/ubuntu/packages focal-security  main restricted universe multiverse

Entry in preseed files

You can configure the Hetzner mirror in the preseed files as follows: (You can replace debian with ubuntu):

d-i mirror/http/hostname string mirror.hetzner.com
d-i mirror/http/directory string /debian/packages
Table of Contents