Skip to main content
NervesHub can store and deploy RAUC bundles (.raucb) alongside fwup archives. Use it for Linux devices built with Yocto or Buildroot that already update with rauc install.
RAUC support is experimental and off by default. It must be turned on for the instance and then for each product.

Requirements

RAUC versions before 1.9 drop [meta.<label>] manifest sections while building a bundle, so the metadata NervesHub needs never reaches it. On the device, bundle.hash was added to slot status in 1.9, and that is how a device reports which bundle it is running.

Enable RAUC

1

Enable it on the instance

Whoever hosts the instance sets RAUC_FIRMWARE_ENABLED=true. Until then no .raucb file is recognised and the product setting below is not shown. See feature prerequisites.
2

Enable it on the product

Open Product settings. On the General tab, in the Firmware card, turn on RAUC bundles.With the CLI:
With the API, set allowed_update_tools on the product:
Listing a format the instance has not enabled returns a 422.
3

Register your signing certificate

See Signing. A bundle is refused until the organization holds a certificate it verifies against.
A product accepts only the formats in allowed_update_tools. The default is ["fwup"], and fwup cannot be removed. Uploading a .raucb to a product that has not opted in is rejected with a message naming the product.

Write the manifest

A RAUC manifest carries compatible and version. NervesHub needs more than that, so add a [meta.nerveshub] section:
NervesHub reads its firmware fields from the manifest like this: Rules to follow:
  • The product must match the name of the NervesHub product you upload to.
  • [update] compatible is required.
  • [update] version must be a valid semantic version, such as 1.4.2. NervesHub does not rewrite RAUC versions.
  • architecture has no fallback. Deployment groups match on it.
  • The bundle must be in the verity format. Plain bundles are refused.

The firmware UUID

RAUC has no firmware UUID, so NervesHub gets one in one of two ways. Derived. Without a declared UUID, NervesHub takes the SHA-256 of the manifest as embedded in the bundle’s signature, and stores the first 128 bits formatted as a UUID. This is the digest RAUC reports as hash in rauc info --output-format=json and records as bundle.hash for the slot it installed into. A device can therefore read the same value back from rauc status after an install. The UUID changes whenever anything in the manifest changes, including the checksum of any image in the bundle. Declared. Set uuid in [meta.nerveshub] to name the firmware yourself. The value must be a UUID. Use this when devices are first flashed by something other than rauc install, such as a factory image. RAUC records a bundle hash only for slots it installed, so such a device cannot report a derived UUID until its first RAUC update. With a declared UUID your build can write the same value into the manifest and into the image. The Linux agent reads it from a file in the root filesystem.

Signing

RAUC signs bundles with CMS against an X.509 keyring, so the key you register with NervesHub is a certificate, not a bare public key.
Register signing-cert.pem with your organization:
In your organization’s settings, under Signing keys, select Add signing key. Choose the RAUC (X.509 certificate) scheme and paste the PEM certificate.
How verification works:
  • A bundle must verify against a certificate registered to the organization, or the upload is rejected.
  • Only the organization’s certificates are trusted. The server’s system CA store is not consulted.
  • If you sign with a leaf certificate issued by your own CA, register the CA certificate. Registering the leaf also works, but then you must register each new leaf when you rotate it.
  • fwup Ed25519 keys and ESP-IDF RSA keys held by the organization are ignored for RAUC.
  • There is no setting to allow unsigned RAUC bundles. RAUC does not build them.
Do not restrict the signing certificate’s extendedKeyUsage to codeSigning. RAUC verifies with the default S/MIME signing purpose, and NervesHub applies the same check, so such a bundle is refused at upload. openssl x509 -purpose should report S/MIME signing : Yes for the certificate.
NervesHub’s check does not replace the device’s. RAUC on the device verifies every bundle against the keyring in its own system.conf.

Upload a bundle

Upload a .raucb the same way as any other firmware. NervesHub identifies the format from the file’s contents, not from its extension.
Open the product’s Firmware page and select Upload firmware.
Then create or update a deployment group as you would for fwup firmware.

Check that it works

After the upload, the firmware appears in the product’s firmware list with the version, platform and architecture from the manifest. If the upload fails, the message says which rule was broken:

Limits

  • No delta updates. NervesHub never generates deltas for RAUC bundles. A deployment group with Delta updates turned on still sends RAUC devices the whole bundle URL. RAUC itself fetches only the blocks the target slot lacks, using HTTP range requests against the bundle.
  • Streaming needs range requests. The Linux agent hands RAUC the firmware URL. The firmware storage behind your instance must honour Range requests, and the download URL must stay valid for the length of the install.
  • Bundle contents are not inspected. What a bundle installs is decided by your manifest and the device’s slot configuration.
  • Archives are separate. Archives are fwup files regardless of the firmware format.