Keyring and Repository Setup

Add the Dash0 package repository to a host, and how the signing certificate is installed and rotated.

This package installs the OpenPGP certificate Dash0 signs its packages and repository indexes with where apt and rpm each look for a third-party archive key.

Installed files

PathPurpose
/usr/share/keyrings/dash0-archive-keyring.pgpThe certificate, dearmored, for apt
/etc/apt/sources.list.d/dash0.sourcesThe repository definition for apt, in deb822 format
/etc/pki/rpm-gpg/RPM-GPG-KEY-dash0The certificate, armoured, for rpm
/etc/yum.repos.d/dash0.repoThe repository definition for dnf and yum
/usr/share/doc/dash0-keyring/README.mdThe installed copy of this page
/usr/share/doc/dash0-keyring/copyrightThe license statement and the notice, DEB only
/usr/share/licenses/dash0-keyring/LICENSEThe license, RPM only
/usr/share/licenses/dash0-keyring/NOTICEThe notice, RPM only

Both certificate files carry the same certificates. apt and rpm expect archive keys in different encodings, so we install both with the same package.

Dependencies

None. Every other Dash0 package depends on this one.

First-time setup

dash0-opentelemetry, like every other Dash0 package, depends on dash0-keyring, so installing it installs this package automatically. The setup below is still needed once per host, because apt and dnf only install packages from a repository they already trust.

The commands below need curl, and sudo or a root shell. Install curl first if the host does not have it.

On a Debian or Ubuntu host, download the certificate and write the sources file:

sudo curl -fsSL https://packages.dash0.com/dash0-archive-keyring.pgp \
  -o /usr/share/keyrings/dash0-archive-keyring.pgp
sudo tee /etc/apt/sources.list.d/dash0.sources > /dev/null <<'EOF'
Types: deb
URIs: https://packages.dash0.com/apt
Suites: stable
Components: main
Signed-By: /usr/share/keyrings/dash0-archive-keyring.pgp
EOF
sudo apt-get update && sudo apt-get install dash0-keyring

On a Fedora, RHEL or Amazon Linux 2023 host, download the certificate and write the repo file:

sudo mkdir -p /etc/pki/rpm-gpg
sudo curl -fsSL https://packages.dash0.com/dash0.asc \
  -o /etc/pki/rpm-gpg/RPM-GPG-KEY-dash0
sudo tee /etc/yum.repos.d/dash0.repo > /dev/null <<'EOF'
[dash0]
name=Dash0
baseurl=https://packages.dash0.com/rpm/packages
enabled=1
gpgcheck=1
repo_gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-dash0
EOF
sudo dnf install dash0-keyring

How the artifact key is used

This package installs the two repository definitions below, the same files the first-time setup writes by hand, so installing it takes over those files and keeps them up to date. To change the settings, add a file of your own next to them instead of editing these, because an upgrade of this package replaces them without asking.

/etc/apt/sources.list.d/dash0.sources:

Types: deb
URIs: https://packages.dash0.com/apt
Suites: stable
Components: main
Signed-By: /usr/share/keyrings/dash0-archive-keyring.pgp

/etc/yum.repos.d/dash0.repo:

[dash0]
name=Dash0
baseurl=https://packages.dash0.com/rpm/packages
enabled=1
gpgcheck=1
repo_gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-dash0

Interplay with pins

An apt pin, a file under /etc/apt/preferences.d/, sets the priority apt gives a repository or a package. Pins are typically used to hold packages at a tested version, or to prefer one repository over another.

This package ships no pin. If you pin the Dash0 repository, leave dash0-keyring upgradable, either by pinning at priority 100 or with an explicit exception for this package. A pin that holds dash0-keyring at its installed version blocks the rotation of the signing key, and the host finds out only when the repository index is re-signed and every apt-get update starts failing.

Key shape

The certificate has a certifying primary key and one signing subkey. Every package signature and every repository index signature is made by the subkey, and the primary key only certifies. The signing subkey does not have a scheduled expiry. An expiry date would not reach rpm 4 hosts that already have the certificate, because rpm 4 never updates a key it has already imported, so it would likely be missed by administrators and strand those hosts.

Rotation

The primary key fingerprint of the current certificate is:

  • 8C3CC81A3D0762F690E85BC37BDF8B3C41E4A849

When Dash0 rotates the signing key, the new fingerprint is added to this list for as long as both certificates are in use.

A rotation reaches a host through an ordinary upgrade of this package, so keep dash0-keyring upgradable. Dash0 first publishes a release of this package that carries both the outgoing and the incoming certificate, and re-signs the repository with the incoming key only after hosts have had time to install it. A host that misses that release cannot verify the re-signed repository, and so never receives the release either: apt reports NO_PUBKEY, and dnf reports Signing key not found. To repair such a host, run the first-time setup again.

On an RPM host, dnf also keeps its own copy of the certificate, which dnf clean all does not remove: under /var/cache/libdnf5/<repoid>-<hash>/pubring/ with dnf5, and under /var/cache/dnf/ with dnf4. If dnf keeps reporting repomd.xml GPG signature verification error: Signing key not found after this package is upgraded, delete that directory.

Removal

Removing dash0-keyring removes the certificate and both repository definitions together, so the host is disconnected from the Dash0 repository instead of being left with a repository it cannot verify. To reconnect the host, run the first-time setup again.

If dash0-keyring was installed as a dependency of another Dash0 package, removing that package can remove it too: dnf removes it in the same command, and apt on the next apt-get autoremove. If it was installed by name, as the first-time setup does, it stays installed until you remove it explicitly.

Last updated: