Brume · Docs
Maintenance

The update mechanism

What instance updates can do on each deployment path, what they refuse to do and why, and what the application can — and cannot — reach to get there.

In brief

Brume separates detecting a new version from applying it. Detection exists everywhere; actuation depends on the deployment path, belongs to the Enterprise edition, and stops dead as soon as a version requires a newer Helm chart — the application deliberately has no rights over the chart.

This page is for the operator deciding whether to trust that automation. To carry it out, go to the upgrade procedure.

Two halves, and only one is automatable everywhere

HalfWhat it doesWhere it lives
DetectionCompares the baked-in version with the backend image's release tags on GHCR, and reads the chart baseline label off the target imageThe trunk, so every edition. The result is cached for an hour
ActuationActually replaces the containers with the new versionThe enterprise add-on, and only where an orchestrator can replace the container

A Community-edition instance therefore always knows a version is waiting; it applies it by hand.

What the mechanism can do, per deployment path

PathActuationHow
KubernetesYesThe backend replaces the image tag on its own Deployment. Kubernetes does the rest: an ordinary rolling update
docker-composeYes, with the updater sidecar runningThe backend drops a version signal into a shared volume; the sidecar consumes it and pulls the images
All-in-one imageNoA single container cannot cleanly replace itself. Detection stays, applying is manual
Helm chartNoNone of these paths raises the chart. The chart-updater component, separate from the application, does — see below

When it fires

The enterprise add-on wakes a scheduler once an hour. It neither detects nor applies anything itself: it consults detection, and decides the when. Three settings, chosen in the superadmin panel:

SettingBehaviour
At a fixed hourThe configured hour opens a window rather than firing on the dot: the update leaves on the first wake-up that follows, so at most an hour later
As soon as it is detectedEvery wake-up that sees a newer version applies it
OffNothing leaves on its own; the button and the command line remain

The hour is read in the BRUME_TIMEZONE zone, UTC by default. Moving the hour earlier reopens the window the same day; moving it later pushes it to tomorrow.

Every wake-up's outcome is recorded and displayed: applied, set aside for want of a chart, or failed, with the version concerned. A silent refusal would let an operator believe they are up to date.

What connected users see

A restart cuts open sockets. A session with an agent in flight is drained — it gets its chance to finish — but someone reading, typing or uploading is cut where they stand. The instance therefore announces its next departure to every connected user, in the sticky banner at the top of the screen: "Brume updates at 22:17", followed by a sentence saying there is nothing to save by hand.

The announced time is the departure, not the setting. Since a slot opens a window rather than firing on the dot, announcing the configured hour would lie by up to an hour: what is announced is the first wake-up following the slot. And nothing is announced when nothing will leave — mode off, no actuation, no newer version, or a version set aside for want of a chart.

The announcement carries that instant alone. Not the mode, not the version, not the actuation state: what an operator configures stays an operator's business. In Community, where nothing is ever scheduled, the banner never appears.

What prevents duplicates

A multi-replica instance does not fire several times: a database advisory lock means a single replica acts per wake-up. And an update already in flight — started by hand, or by an earlier wake-up whose process has since died — is not started again on top.

What it cannot do, and why

This is the section to read before letting the automation run.

It does not raise the Helm chart. That is the limit every other one follows from. A release can declare that images alone are not enough; the automation then sets it aside, and the button disappears from the interface. This is not an omission: the application's rights deliberately stop at the image tag, and applying the image alone would leave the instance half mounted — new code, old templates.

It never rolls back. No path — not the button, not the scheduler, not the chart-updater — decides on a rollback. A failure is reported, not repaired: judging whether to run helm rollback is yours.

It does not undo migrations. They are forward-only and run when the new backend starts, outside this mechanism. Returning to the previous image therefore does not bring back the previous schema: the old image must remain compatible with the migrated database.

It does not update a stack built from source. Pulling an image assumes a published image and a moving channel tag; a build: stack is rebuilt instead.

It does not apply to the second. Detection caches its results for an hour and the scheduler wakes at the same cadence, so as not to query the registry more often. The configured hour is a window, not an appointment.

It watches nothing afterwards. The mechanism replaces the containers and stops there; the rolling update, the probes, and monitoring are what tell you whether the instance is healthy.

The security model

The question fits in one sentence: an application exposed on the internet, running models, must never hold the power to rewrite itself. Each path answers differently.

On Kubernetes: a role bounded to one line

The self-update ServiceAccount is a namespaced Role, never a ClusterRole, with get and patch as its only verbs, and a resourceNames locked to the backend's single Deployment. It sees neither the other components nor the cluster.

The trade-off, to know before enabling

patch on a Deployment is not field-scoped. At the RBAC-object level this account touches one Deployment; but a compromised backend could rewrite its own pod template — mount any Secret in the namespace, change ServiceAccount, alter its securityContext. Enabling self-update therefore widens what arbitrary code execution in the backend yields, up to namespace-secret reach. That is why this path is off by default. Pair it with a restricted Pod Security level, and ideally with an admission policy that rejects any patch by this account touching anything other than the backend container's image tag.

On docker-compose: the application never sees the socket

The Docker socket is root-equivalent on the host: it is mounted only in the updater sidecar, which is opt-in. The application writes a file into a shared volume — a version, never a command. The sidecar knows how to do nothing but pull images from the committed compose file, for the configured service list. A compromised backend therefore cannot make it run anything else.

The chart-updater: the power lives elsewhere

Raising a chart does require broad rights: Helm stores its releases as Secrets and must be able to replace every object the chart owns, so reading every secret in the namespace is unavoidable. That power is never handed to the application: it lives in a separate CronJob, with its own account, which listens on nothing, runs a script committed in the chart, and only ever installs the chart its configuration names. That account is namespace-admin-equivalent; what bounds it is its attack surface, not its rights.

The default state, and what changes it

CapabilityBy defaultWhat changes it
Detecting a new versionOn, every editionTurned off by environment variable
Actuation from the applicationOff outside the enterprise edition, and outside a capable orchestratorAn enterprise licence, plus the deployment path: the self-update role on Kubernetes, the selfupdate profile on docker-compose
Automatic applicationOn as soon as actuation is: at a fixed hour, at midnightThe superadmin panel setting — hour, immediate mode, or off
Automatic chart upgradeOffThe chart-updater component, enabled in the chart values

An instance that touches nothing therefore detects versions and raises none: without an enterprise licence and without actuation rights, there is nobody to act. An enterprise instance whose actuation is in place, by contrast, keeps itself up to date on the versions that need no chart — that is the deliberate default, and the switch is in the superadmin panel.

Next

The matching gestures — enable, set, disable, roll back — are in the upgrade procedure. What a given release requires is in the release notes.

On this page