arcave

module
v0.1.0-alpha.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 19, 2026 License: Apache-2.0

README

arcave

arcave

Ephemeral environments and branching for your Docker Compose project

arcave saves the whole live state of a running Compose project — every volume, every container filesystem, and the compose spec itself — and puts it back in one command. Get your environment to the state you want, save it, and come back to it in seconds.

It works on any Compose project, on the Docker you already have.

Alpha. arcave is at v0.1.0-alpha.1. Commands, output and the storage format may change between alphas, with no migration path for savepoints taken by an earlier one. It is not ready for production use yet.

Discord

Documentation License GitHub Release GitHub Downloads (all assets, all releases)

arcave savepoint create before-migration
# ...run the migration, the test suite, the agent...
arcave rollback before-migration

Key Features

  • Whole-project savepoints: One savepoint holds every stateful volume, every container's writable layer, and the compose spec the project was running under.
  • Consistent by construction: The services are stopped before a byte is read, so nothing is captured mid-write and a database comes back without a crash-recovery pass on start.
  • Reversible rollback: A rollback takes a safety snapshot of what it is about to overwrite and replays it automatically if anything fails. A failed rollback leaves you where you started.
  • Sessions and branching: Independent lines of savepoints inside one project. A fork copies a whole session into a new one, and the two lines never mix.
  • Incremental capture: The cdc backend writes only the chunks that changed since the last savepoint. Container filesystems and images are deduplicated by default, whichever volume backend you pick — the base layer every savepoint shares is stored once.
  • Built for agents: arcave mcp serves savepoint create, list, remove and rollback — and the session commands — as MCP tools, so an agent checkpoints before it acts, rolls back when validation fails, and can fork a session of its own.
  • Plain Docker: No ZFS, no copy-on-write filesystem, no storage appliance, no Docker daemon to reconfigure — the daemon you already run, and the arcave binary.
  • Any compose project: Postgres, MySQL, Kafka, Redis, MinIO, your own services. No allowlist — arcave reads what your Docker daemon is running.

Use Cases

  • Testing destructive migrations: Run the migration against real data, again and again, until it is right. The reset is one command.
  • Agent iteration loops: Give an autonomous agent a checkpoint per attempt, and a failed iteration costs a rollback instead of a rebuild.
  • Environment branching: A session per feature branch, forked off a shared baseline and switched by name.
  • Resetting fixtures and demos: Seed the environment once, save it, and return to that exact state for the rest of the project's life — object storage and cache included.

Quick Start

# 1. Install the binary
curl -fsSL https://greenmask.io/arcave/install.sh | bash

# 2. Bring your compose project up and initialise arcave in it
docker compose up -d
arcave init
export ARCAVE_PROJECT_NAME=myapp     # as `docker compose ls` names it

# 3. Save the state you want to come back to
arcave savepoint create before-migration

# 4. ...run the migration, the experiment, the agent...

# 5. Go back to it
arcave rollback before-migration

For more details, visit the Documentation — start with Getting started, and read the Limitations before you build a workflow on arcave.

Requirements

  • Docker 25 or newer, with the daemon reachable by the user running arcave.
  • Linux or macOS. There is no Windows build.

The full list is in Requirements.

Powered by

JetBrains logo.

Directories

Path Synopsis
cmd
arcave command
internal
cli
Package cli adapts arcave's services to Cobra commands: each handler invokes a service method and renders the result through a printer — the model types go out as JSON (Savepoint for single-savepoint payloads, the response envelopes for multi-part responses).
Package cli adapts arcave's services to Cobra commands: each handler invokes a service method and renders the result through a printer — the model types go out as JSON (Savepoint for single-savepoint payloads, the response envelopes for multi-part responses).
client/docker
Package docker acts on the *running* compose project, in contrast to internal/client/ compose, which only reads what the compose files declare.
Package docker acts on the *running* compose project, in contrast to internal/client/ compose, which only reads what the compose files declare.
config
Package config defines arcave's per-project configuration value type, the pure helpers that seed and validate it, and Unmarshal — the single home of the config policy (unknown-key rejection, defaults, validation).
Package config defines arcave's per-project configuration value type, the pure helpers that seed and validate it, and Unmarshal — the single home of the config policy (unknown-key rejection, defaults, validation).
model
Package model holds arcave's shared domain types, passed between the repository, client, service, and adapter layers.
Package model holds arcave's shared domain types, passed between the repository, client, service, and adapter layers.
repository/config
Package config persists arcave's per-project configuration to .arcave/config.yaml.
Package config persists arcave's per-project configuration to .arcave/config.yaml.
repository/currentsession
Package currentsession persists the host-local current-session pointer, .arcave/current_session.
Package currentsession persists the host-local current-session pointer, .arcave/current_session.
repository/inflight
Package inflight persists the rollback intent marker, .arcave/inflight.json.
Package inflight persists the rollback intent marker, .arcave/inflight.json.
repository/savepoint
Package savepoint reads and writes savepoint records — one JSON object per savepoint, stored at the root of that savepoint's own namespace.
Package savepoint reads and writes savepoint records — one JSON object per savepoint, stored at the root of that savepoint's own namespace.
repository/session
Package session reads and writes session records at sessions/<id>/session.json.
Package session reads and writes session records at sessions/<id>/session.json.
service/backend/fullcopy
Package fullcopy captures a volume wholesale: one tar archive per volume per snapshot, under <snapshotID>/<objectID>/, streamed through the Docker engine and stored verbatim so ownership and permissions survive a restore.
Package fullcopy captures a volume wholesale: one tar archive per volume per snapshot, under <snapshotID>/<objectID>/, streamed through the Docker engine and stored verbatim so ownership and permissions survive a restore.
service/backend/imagecopy
Package imagecopy is the vocabulary two image backends stand on: where a capture lives, what it reaches the daemon through, and how it describes itself.
Package imagecopy is the vocabulary two image backends stand on: where a capture lives, what it reaches the daemon through, and how it describes itself.
service/backend/imagecopy/dedupcopy
Package dedupcopy splits a container's committed image between a content-addressed blob store shared by every capture and that capture's own metadata, so a base layer every savepoint carries is written once.
Package dedupcopy splits a container's committed image between a content-addressed blob store shared by every capture and that capture's own metadata, so a base layer every savepoint carries is written once.
service/backend/imagecopy/fullcopy
Package fullcopy keeps a container's committed image as the archive the daemon handed over: one object per capture, nothing shared, nothing addressable.
Package fullcopy keeps a container's committed image as the archive the daemon handed over: one object per capture, nothing shared, nothing addressable.
service/backend/restic/cdc
Package cdc captures a volume into a restic repository that outlives any one snapshot, writing only the chunks that changed.
Package cdc captures a volume into a restic repository that outlives any one snapshot, writing only the chunks that changed.
service/backend/restic/rest
Package rest assembles the restic REST backend: the generated routes over the handler, the middleware they run behind, and the OpenAPI document they were generated from.
Package rest assembles the restic REST backend: the generated routes over the handler, the middleware they run behind, and the OpenAPI document they were generated from.
service/backend/restic/rest/api
Package api provides primitives to interact with the openapi HTTP API.
Package api provides primitives to interact with the openapi HTTP API.
service/backend/restic/rest/docs/api
Package docs carries the OpenAPI document the api package is generated from, embedded in the binary so that what a reader is served is the contract the routes were built from, with no file to keep beside the executable.
Package docs carries the OpenAPI document the api package is generated from, embedded in the binary so that what a reader is served is the contract the routes were built from, with no file to keep beside the executable.
service/backend/restic/rest/model
Package model holds the vocabulary of one restic repository: how an object is addressed and which failures the protocol has a status for.
Package model holds the vocabulary of one restic repository: how an object is addressed and which failures the protocol has a status for.
service/backend/restic/rest/repo
Package repo holds the objects of one restic repository: which key each lands under, and which store failure is one of the two conditions the protocol has a status for.
Package repo holds the objects of one restic repository: which key each lands under, and which store failure is one of the two conditions the protocol has a status for.
service/capturepolicy
Package capturepolicy reads a compose project's arcave.* labels and the config's defaults into the capture decision for every resource, and spells the decisions back out as labels for the spec a savepoint records.
Package capturepolicy reads a compose project's arcave.* labels and the config's defaults into the capture decision for every resource, and spells the decisions back out as labels for the spec a savepoint records.
service/composespec
Package composespec builds the compose spec of a live compose project from model.IntrospectionResult, complete enough to create it anew.
Package composespec builds the compose spec of a live compose project from model.IntrospectionResult, complete enough to create it anew.
service/heartbeat
Package heartbeat keeps a running operation's heartbeat fresh, and reads one back.
Package heartbeat keeps a running operation's heartbeat fresh, and reads one back.
service/introspect
Package introspect reports a compose project as the daemon holds it, in one pass: services, their mounts, the project's volumes and networks, the images its containers run on, and `docker info`.
Package introspect reports a compose project as the daemon holds it, in one pass: services, their mounts, the project's volumes and networks, the images its containers run on, and `docker info`.
service/lock
Package lock serialises the arcave workflows that mutate a project.
Package lock serialises the arcave workflows that mutate a project.
storefactory
Package storefactory turns a config.Storage union into the storages.Storager the backends write through.
Package storefactory turns a config.Storage union into the storages.Storager the backends write through.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL