Skip to content
Latchkey

GoReleaser nfpm rpm/deb packaging failed in CI

GoReleaser uses nfpm to build Linux packages (deb, rpm, apk). Packaging fails when a required field like maintainer is missing, or when a requested format needs external tooling that is absent.

What this error means

GoReleaser fails at the nfpm step with "nfpm failed" citing a required field (for example maintainer) or an error building the rpm or deb.

Terminal
  ⨯ nfpm failed  error=first pass: nfpm failed: package maintainer must be provided

Common causes

A required nfpm field is missing

rpm and deb require metadata such as maintainer; nfpm refuses to build without it.

A requested format needs external tooling

Some package features (signing, certain compressions) need tools the runner does not have.

How to fix it

Fill in required package metadata

  1. Add the required nfpm fields, including maintainer and formats.
  2. Set id, package_name, and a description for the packages.
  3. Re-run so nfpm has everything it needs to build.
.goreleaser.yaml
nfpms:
  - maintainer: Acme <dev@acme.example>
    description: Acme CLI
    formats: [deb, rpm]

Install tooling for the requested format

If a format needs external tools, install them on the runner before GoReleaser runs.

Terminal
sudo apt-get update && sudo apt-get install -y rpm

How to prevent it

  • Provide all required nfpm metadata in the config.
  • Run goreleaser check so missing package fields surface early.
  • Install format-specific tooling in a setup step.

Related guides

Tired of flaky CI? Latchkey auto-heals failed jobs and retries them for you. Start free →