# Runner security

> How flockvm isolates GitHub Actions jobs: one microVM per job deleted after, single-use runners, no SSH, private repositories only, network abuse checks.

- URL: https://flockvm.com/docs/ci/security
- Section: GitHub Actions
- Last updated: 2026-10-31

Every flockvm job runs in its own Firecracker microVM, which is deleted when the job ends. This page explains what that protects, what it does not, and the GitHub settings worth checking.

## One VM per job, destroyed after

- A runner VM is created for **one** job and deleted when that job ends. It is never paused, restarted or reused for another job, even of the same repository.
- Nothing of a job survives into the next one: no files, no processes, no Docker images, no credentials.
- The VM has the same isolation as any flockvm VM: Firecracker with the jailer, its own unprivileged user on the host, its own network interface, and a host firewall that keeps it away from the host. See [Isolation](https://flockvm.com/docs/security/isolation).

## Single-use runners

flockvm registers a **just-in-time (JIT)** runner on your repository for each job. Its configuration is valid for one job: the runner registers, takes the job GitHub assigned to it, and exits.

- The JIT configuration reaches the VM through its metadata service. It is never written to a log, and it is erased from flockvm's records when the VM is deleted.
- Inside the VM it is visible to the job's own processes for the job's duration, as on any self-hosted runner.
- When the job ends, flockvm deletes the runner from your repository if it is still registered. Your repository's **Settings → Actions → Runners** list does not fill up with old runners.

Why single-use runners matter, and how JIT runners compare with `--ephemeral` ones, is in [ephemeral GitHub Actions runners](https://flockvm.com/learn/ephemeral-github-actions-runners). The risks of a self-hosted runner in general, and the settings that limit them, are in [self-hosted runner security](https://flockvm.com/learn/self-hosted-runner-security).

## No SSH into runners

A runner VM gets no SSH key. Nobody can log in to it, you included: on the dashboard it shows with a **CI** badge and **Runs a CI job** instead of an SSH command and actions.

To debug a job, print what you need from its steps, upload files with `actions/upload-artifact`, or reproduce it in a regular [VM](https://flockvm.com/docs/vms/create) that you can [SSH into](https://flockvm.com/docs/vms/ssh).

## Secrets

Your GitHub Actions secrets reach the runner VM the way GitHub sends them to any runner, for the steps that use them. They live in that VM only, and are gone with it when the job ends.

flockvm keeps the GitHub App's private key on its host, readable by root only, and never logs a key, token or runner configuration.

> **Tip:** Give `GITHUB_TOKEN` only what a job needs with `permissions:`, the same advice as for any runner.
>
> ```yaml
> permissions:
>   contents: read
> ```

## Public repositories

flockvm runs jobs of **private** repositories only. A job from a public repository is stored as failed at once, with the reason **public repository: flockvm runs jobs of private repositories only on this host (FLOCK_CI_PUBLIC_REPOS)**. It gets no runner and no VM, and costs nothing.

Why: anyone can open a pull request on a public repository, and with GitHub's default settings the pull request's workflow runs on the repository's runners. That is a stranger's code running on a VM your organization pays for, with network access. The VM is thrown away after, but the code still runs. GitHub itself advises against self-hosted runners on public repositories.

Keep public repositories on GitHub-hosted runners: use `runs-on: ubuntu-latest` there, or a condition.

```yaml
jobs:
  test:
    runs-on: ${{ github.event.repository.private && 'flockvm' || 'ubuntu-latest' }}
```

## What the GitHub App can do

The flockvm GitHub App asks for these repository permissions only, on the repositories you select:

| Permission                       | Why                                                                                                                             |
| -------------------------------- | ------------------------------------------------------------------------------------------------------------------------------- |
| **Administration: Read & write** | Register and remove the job's just-in-time runner on the repository                                                             |
| **Actions: Read**                | Look up a job's state on GitHub                                                                                                 |
| **Contents: Read**               | Clone the repositories you pick in an [environment](https://flockvm.com/docs/vms/environments#github-repositories) into new VMs |
| **Metadata: Read**               | Required by GitHub for every App                                                                                                |

It subscribes to **Workflow job** events. It asks for no **Contents: Write** and no **Actions: Write**: flockvm cannot push to your repositories, nor cancel or re-run your workflows. The token a VM gets for a clone is narrower still: read-only, for the environment's repositories only, and it expires within the hour.

GitHub signs every webhook it sends. flockvm checks the signature before it reads anything, and ignores a delivery it has already handled.

## Recommended GitHub settings

- **Install the App on selected repositories only**, the ones you want on flockvm. You can change the list any time from **Repositories on GitHub ›** on the CI page ([Setup](https://flockvm.com/docs/ci/setup#change-the-repositories)).
- **Restrict who can change workflows.** Anyone who can push a workflow to a connected repository can run jobs on flockvm, billed to your organization. Use branch protection and required reviews for `.github/workflows/`.
- **Set `permissions:`** on workflows, as above.
- **Require approval for fork pull request workflows** (repository or organization **Settings → Actions → General**). flockvm refuses public repositories anyway, but this also covers forks of private repositories if your organization allows them.
- **Set `timeout-minutes`** on jobs, so a stuck job stops before the [6-hour limit](https://flockvm.com/docs/ci/limits#job-timeout).

## Abuse detection on runners

Runner VMs go through the same host-side abuse checks as every flockvm VM, with one exception. flockvm never looks inside a VM: it watches what the host sees.

| Check                                                                          | On runner VMs                              |
| ------------------------------------------------------------------------------ | ------------------------------------------ |
| CPU at full load for a long time                                               | **Not watched.** That is what a build does |
| Port scans, SSH brute force, floods, outgoing mail (SMTP)                      | Watched                                    |
| Connections to known-bad destinations (blocklists, mining pools, mining ports) | Watched                                    |

A runner VM that triggers a serious network signal can be cut off from the network like any VM. Its job then fails or times out, and the VM is still deleted at the end of the job. See [Acceptable use](https://flockvm.com/docs/security/acceptable-use).

## Next steps

- [Isolation](https://flockvm.com/docs/security/isolation): How Firecracker and the jailer isolate VMs.
- [Data residency](https://flockvm.com/docs/security/data-residency): Where your jobs run and your data lives.
- [Limits](https://flockvm.com/docs/ci/limits): Timeouts, concurrency, platforms.
