Skip to main content
A snapshot is a saved desktop image. A custom environment boots from it, so every run starts with your software already installed and set up. Build a snapshot only when it pays off. Use one when each run would otherwise spend time installing or setting up the same thing. If the base image already has what your workflow needs, use the base. Snapshots work for the Linux, Windows and Citrix environment types. A browser environment has no snapshot.

Who can build one

Building a snapshot needs a plan that includes it, and the operating system of the image. Without them, a capture is refused with a 403. An organization admin upgrades the plan. Your organization’s snapshots are private to it. Your organization can also boot the shared snapshots that Asteroid publishes, for each operating system its plan includes.

Build on a base

A base is one of the three shared operating system images: Every snapshot starts from a base. That keeps its recipe complete, so you can rebuild the snapshot on a newer base by replaying the recipe. Do not start a new snapshot from another snapshot, your own or a shared one. Its recipe would then depend on that snapshot, and could not rebuild the image from a base.

Build or change a snapshot

Ask Astro: “Build a Linux snapshot with LibreOffice installed.” Astro boots the base, installs the software, writes the recipe and captures. It asks you before it captures. An environment Astro started belongs to that chat. Only that chat can read or capture it. To do it yourself with the CLI (the MCP tools and the API have the same operations):
1

Boot the base, or the snapshot to change

Set osType to windows or citrix for those bases. To change a snapshot, set snapshotName to its name.
2

Install and set up

Open the environment’s live view on the Environments page, Instances tab. Install the software and set up the screen the way every run should find it. Note each step for the recipe.
3

Read the current recipe

This shows the version the machine holds. It shows the recipe only when one is on record and the snapshot is not shared. A base has none, so a new snapshot needs a full recipe. Otherwise edit that recipe rather than writing a new one. If newerVersion is set, the machine is not the newest version: a capture would drop that version’s changes. Boot the newest version first.
4

Capture

Run it once. See What a capture does.
5

Stop the environment

The recipe

Each version should carry a recipe: markdown that rebuilds the image on a fresh base, with no other context. It has these sections: A recipe has no frontmatter and at most 20000 characters. A changelog has at most 500. A new recipe replaces the old one. So it covers every step from the base, not only the last capture’s. Never write a password, token or other secret in it. Sign-ins belong in profiles. Always send a recipe on a snapshot’s first capture. The capture does not require one, and a version stored without a recipe cannot be rebuilt. Leave out --recipe only to keep the recipe of the version the machine booted, when that version is of the same snapshot.

What a capture does

  • It takes minutes, and the command waits until it finishes.
  • Linux and Citrix restart. The machine is stopped, imaged and started again. The session ends and the screen is back at its boot state. Windows is imaged with its memory and keeps running.
  • Each capture adds a version. Do not retry one. If the command times out or returns a 5xx error, the capture can still finish. Run asteroid environment-snapshot list and look for the new version first.
  • A name is yours once used. A capture under a name your organization already uses adds the next version to that snapshot. A new snapshot cannot take a shared snapshot’s name, such as linux-base.

Versions and pins

Versions are numbered like 1.2.0. Each change takes the next minor version: 1.2.0, then 1.3.0. To boot a snapshot, set its name as the Snapshot of a custom environment (base.snapshotName on the API), then bind the workflow to that environment. asteroid environment-snapshot list shows each snapshot’s name and versions, newest first. Pin a minor or exact version when a workflow must not change until you move it.

Propose, test and accept

A change to a snapshot that workflows boot by bare name reaches them at their next run. To test it first, capture it as a proposal:
  1. The capture is stored as a pre-release, such as 1.3.0-rc.1, and returns its proposalId. Only that exact pin boots it. Every other pin keeps its version.
  2. Test it: boot crm-desktop:1.3.0-rc.1 in a live environment, or in a custom environment that a test workflow uses.
  3. asteroid environment-snapshot get <snapshot-id> lists the open proposals, if you need the id again.
  4. Accept it with asteroid environment-snapshot proposal accept <snapshot-id> <proposal-id>. It is released as 1.3.0. Bare-name pins boot it from then on. A minor pin such as crm-desktop:1.2, and an exact pin such as crm-desktop:1.2.0, stay where they are.
  5. Or close it with asteroid environment-snapshot proposal dismiss <snapshot-id> <proposal-id>.
A proposal must change the newest version. A snapshot with no version yet cannot take one: capture its first version without --propose. Each proposal is a separate pre-release: a second capture with --propose adds 1.3.0-rc.2, so dismiss the ones you do not keep.

Errors

A capture error about the environment or the snapshot name starts with environment cannot be snapshotted: . The table leaves that prefix out. Recipe and changelog errors have no prefix. “Boot” is environment start, and any run that boots the snapshot.