Promoting Preview to Live

Promotion is the one control that moves work from your preview site to your live site. Everything preview has that live does not, released as a single deployment.

The button is on the Deploy screen, in the Preview site card, colored pink: Push preview live. Under it, whenever it is unavailable, is a line of text saying why — and that line is the most useful thing on this page.

What promotion actually moves

It moves the current state of your preview site. Not a selection, not the changes since last time, not the ones you approve — the whole thing, as one unit, in one deployment badged Promoted Preview => Public.

That is most often template and layout work: a developer’s CLI pushes, styling changes. It is the whole reason the preview site exists — preview and live are two separate sites, and this button is the bridge between them.

When the button is available

Five conditions have to hold at once. Any one of them failing grays the button out and prints the reason underneath.

  1. You hold deployment:promote — the Content Publisher role or above, or a Developer access override on a lower role.
  2. Preview is genuinely ahead of live.
  3. Preview is not mid-build.
  4. Nothing on the preview branch is still waiting to be built — the preview you are looking at is the newest thing on it.
  5. No promotion is already running.

“Ahead” has a precise meaning

Leed does not diff the two sites. It takes the commit the newest preview deployment was built from and asks whether that commit has ever reached the live site: preview is ahead when it has a deployment and its commit appears on no live deployment at all.

That is a commit-identity check, not a count of changes. Two consequences follow, and both surprise people:

  • A change that produces an identical result still counts as ahead, because it is a different commit.
  • Publishing to live does not make preview look ahead. A page publish or a Pending changes publish lands on live as a new commit of its own, but the preview commit you already promoted is still on live, so the button stays at Nothing new to push live. until something new reaches preview.

Every reason it is disabled, verbatim

The hint under the button is evaluated in a fixed order and only ever shows one line. Four of the seven render as small gray text; the other three are red alert boxes, split across two lines at the sentence break, because they are real blockers rather than status reports.

What you seeToneWhat it meansWhat to do
You don't have permission to push live.mutedYou lack deployment:promote and have no Developer overrideAsk an administrator for the Content Publisher role or the Developer checkbox
Pushing live — merging staging → main…mutedYour own promotion is in flight right nowWait — this clears itself
Preview is still building. Wait for it to finish.mutedThe newest preview deployment has not settledWait for its row to reach Active
Blocked: the preview site's latest deployment failed. Resolve the error before promoting to public.red alertThe newest preview build failedFix the failure and publish to preview again
Blocked: the preview site is still building. Wait for it to finish.red alertSame condition as the third row, reported by the server rather than the browserWait
Blocked: the preview branch has commits that have not been built yet. Wait for the preview build to finish.red alertSomething reached the preview branch after the newest preview deployment was built, so promoting now would release more than the preview you can seeWait for the new preview build to finish
Nothing new to push live.mutedThe newest preview commit is already on the live siteNothing is wrong — there is genuinely nothing to release

Two rows say the same thing in different words because two layers check it independently: the browser checks the deployment it is already displaying, and the server re-checks before answering. Both wordings are real and you may see either.

The Preview site card with a red alert reading Blocked: the preview site's latest deployment failed, and a grayed-out Push preview live button
Blocked by a failed preview build — the fix is always on the preview side, never here
The Preview site card showing the muted hint Nothing new to push live under a disabled button
The ordinary steady state: preview and live were built from the same commit, so there is nothing to release

The second is the state you will see most of the time, and it is not an error. Preview and live agree.

If the red alert says the preview build failed, start with the failure page — the fix is always on the preview side. A content or template error has to be corrected and pushed again; an infrastructure failure can be retried from the row itself.

What happens while it runs

Press the button and, in this order:

  1. The button changes to Pushing live… and its hint becomes “Pushing live — merging staging → main…”.
  2. A Promotion started toast appears. If it turns out there was nothing to move, the toast says so instead — Nothing to promote — the public site already matches the preview. or Already promoted — this preview commit is on the public site. — and no new row is created.
  3. A new row lands in the Live site history column badged Promoted Preview => Public, with your name on it — reading the history.

Underneath, Leed merges the site repository’s staging branch into main — reusing an open merge request if one exists, and opening one if not — then starts an ordinary live build of the merged result. The merge is pinned to the exact commit your preview was built from, so a push that lands on staging in the seconds after you click cannot ride along unseen: GitLab refuses the merge and nothing is promoted. From there it is the same pipeline as any other deployment: build, upload a version, activate it.

One asymmetry is worth knowing. Publishing to live normally fires a parallel preview rebuild so preview does not fall behind. A promotion skips that, because preview is by definition already in sync with what you just released. So a promotion produces one row, not two.

Promotion is also available outside the browser, for a developer or a release script: leed deployments promote from the CLI, or the promote_staging_to_production tool over MCP. Both ask for confirmation first, and both are safe to repeat — a promotion that has already happened, or one with nothing to move, answers with that outcome rather than an error and starts no build.

If you get an error instead

The server re-checks the conditions when it receives the request, so a state that changed between the page loading and you clicking is caught there rather than in the browser. The three state refusals are 409 Conflict; a merge that GitLab would not complete is a 502.

HTTP statusServer messageWhat the CMS shows you
409Preview site's latest deployment is in an error state. Resolve and retry.“The preview site’s latest deployment failed. Resolve it before promoting.”
409Preview site is still building. Wait for it to finish before promoting.“The preview site’s latest deployment failed. Resolve it before promoting.”
409The preview branch has commits that have not been built yet, so promoting now would publish more than the preview you are looking at. Wait for the preview build to finish, then promote.“The preview site’s latest deployment failed. Resolve it before promoting.”
502The staging→main merge did not complete. Nothing was promoted; check the merge request in GitLab.The server’s message, as an error. Nothing was written, so trying again is safe

Promotion versus publishing

Two buttons on the same screen, both of which put something on your live site. The difference is what they carry.

Publish N to live sitePush preview live
MovesCMS records — labels, menus, forms, settings, team profilesfiles — templates, layouts, anything a developer pushed
Sourcethe Pending changes listthe current state of the preview site
Selectiontick exactly what you wantall of it, no selection
Reason badgeone per kind of item tickedPromoted Preview => Public

Reaching for the wrong one is harmless — neither can move the other’s work — but it does waste a build. Rule of thumb: if you changed it by typing in the CMS, publish it. If it arrived as a file, promote it.

A developer who has just pushed will usually want this button next — what their push already did covers the half that happens before you get here, and the CLI side is in Validate, Commit and Push.

ESC