Signing keys (Apt & Yum)
Hosted Apt and Yum repositories sign their metadata with an OpenPGP key that Entrepot manages per repository:
- Apt:
InRelease(clear-signed) andRelease.gpg(detached). - Yum:
repomd.xml.asc(detached, armored) — enablerepo_gpgcheck=1.
The key is generated the first time the repository’s metadata is signed (RSA-4096, accepted by every apt/gpgv and dnf/librepo release in use). The private key is encrypted at rest; a rotation on one replica takes effect on all of them immediately.
Proxy repositories don’t sign anything: they serve the upstream’s own signed metadata byte for byte.
Distribute the public key
Section titled “Distribute the public key”| URL | Format |
|---|---|
https://entrepot.example.com/repository/<repo>/public.gpg |
binary keyring (Apt signed-by) |
https://entrepot.example.com/repository/<repo>/public.key |
ASCII-armored (Yum gpgkey, apt-key-free imports) |
Or read it through the API, which also returns the fingerprint:
curl -fsS -H "Authorization: Bearer $ENTREPOT_TOKEN" \ https://entrepot.example.com/api/v1/repositories/apt-internal/signing-key{"fingerprint":"…","algorithm":"…","publicKey":"-----BEGIN PGP PUBLIC KEY BLOCK-----…","url":"https://entrepot.example.com/repository/apt-internal/public.key","createdAt":"…"}Rotate
Section titled “Rotate”Generate a new key and re-sign the metadata (admin only):
curl -fsS -H "Authorization: Bearer $ADMIN" -X POST \ https://entrepot.example.com/api/v1/repositories/apt-internal/signing-key/rotateImport your own key
Section titled “Import your own key”If you already have a release key (for example one your fleet trusts), import it instead of using a generated one:
jq -n --rawfile k release-key.asc --arg p "$PASSPHRASE" '{privateKey: $k, passphrase: $p}' \ | curl -fsS -H "Authorization: Bearer $ADMIN" -H 'Content-Type: application/json' -X PUT \ https://entrepot.example.com/api/v1/repositories/apt-internal/signing-key -d @-resource "entrepot_repository_signing_key" "apt_internal" { repository = entrepot_repository.apt_internal.name private_key = file("release-key.asc") passphrase = var.release_key_passphrase}The private key must be ASCII-armored and able to sign. The passphrase is only needed to decrypt it on import. Both are write-only.