# Builds sent from CI

Let GitHub Actions or GitLab CI build your site and send the build to Fuzops, which publishes it like any other update. Set-up, secret and limits.

Normally your server downloads the code and builds it on every update. With **Build elsewhere, publish here**, your CI service (such as GitHub Actions or GitLab CI) prepares the site and sends the finished build; Fuzops publishes it like any other update. Technical name: CI artifact deploy.

Use it when builds are heavy for your server, when your CI already builds and tests the site, or when you want only builds that passed your tests to go live.

## Turn it on

1. Open the site, then **Updates** › **Update settings**.
2. Under **Build elsewhere, publish here**, turn on **Publish the builds my CI sends**.
3. Choose **Make a secret** and copy it. It is shown only once.
4. In your CI, save it as a secret with the name the page gives. On GitHub: **Settings** › **Secrets and variables** › **Actions**.
5. Add the CI file:
   - **GitHub Actions**: the page shows a workflow file made for your kind of site and branch. **Copy the file** and save it in your repository at the path shown, or choose **Add this file to my repository** when your GitHub account is connected under **Code hosting**.
   - **GitLab CI**: open **Using GitLab CI instead** and copy the job into your `.gitlab-ci.yml`. Save the secret as a masked CI/CD variable.

![Build elsewhere, publish here in the site's Update settings, turned off](https://internal.fuzops.com/docs-img/site-ci-builds.webp "Build elsewhere, publish here, before it is turned on.")

From then on, each build your CI sends for that branch becomes an update. Pushing code alone no longer publishes anything.

## What Fuzops does with a build

- The build is a `.zip` or `.tar.gz` file, sent to the **Publish address** shown on the page, with the secret.
- Your **update steps** stay as they are: the server still prepares what your CI sends (for example linking shared files and running database migrations), then switches visitors over. Steps that build the site can be turned off, since your CI already did it.
- The update appears in the site's **Updates** like any other, and you can go back to the version before.
- **Largest build** on the page says how big a build can be.

## The secret

- The secret is shown once. If you lose it, **Make a new secret**; the old one stops working at once, so update it in your CI.
- **Stop the secret** turns publishing from CI off until you make a new one.
- Only people whose role may see the site's secrets can change this. See [Team, roles and access](https://internal.fuzops.com/docs/team-and-access).

## Turn it off

Turn off **Publish the builds my CI sends** and confirm **Build on the server**. Your server goes back to downloading and building the code on every update.

> **Tip:**
> Watch the first run in your CI and in the site's **Updates** before you rely on it. If your CI already has its own build steps, adjust the file rather than running both.

## Related

- [Guide: publish builds from GitHub Actions](https://internal.fuzops.com/docs/guides/publish-builds-from-github-actions)
- [Updates](https://internal.fuzops.com/docs/updates)
