---
title: Persistent Services
url: "/docs/apps/persistent-services/"
canonical_url: https://docs.blossom88.com/docs/apps/persistent-services/
markdown_url: https://docs.blossom88.com/docs/apps/persistent-services.md
summary: Run a custom image with a Volume that keeps its data across Container replacements.
categories:
- applications
- storage
---

# Persistent Services

A Persistent Service runs your image with a Volume mounted at a path such
as `/data`. Its files survive Container replacements and app updates.
Use it for an app's local uploads, a custom database, or another component
that needs a filesystem.

[Supabase](/guides/supabase/) uses Persistent Services for
its PostgreSQL distribution, uploaded files, and saved Studio snippets.
It is a useful option when an app needs something beyond Blossom's
[supported managed Databases](/docs/databases/).

## Choose Where It Runs

| Choice | Compute | Storage |
|---|---|---|
| Shared | Shares your Persistent Capacity with your other Persistent Services | Its own Volume |
| Dedicated | Reserves compute for this Service | Its own Volume |

Both run on Servers assigned to your Account. Persistent Capacity is separate
from regular App Capacity and Managed Data Capacity.

## Ask Your Agent

> **Ask your AI agent:** Deploy this image as a Persistent Service and keep its data across updates.

> Follow this guide: https://docs.blossom88.com/docs/apps/persistent-services/



Your agent chooses the mount path, Volume size, and Container allocation for
the app. In service.yml, it adds storage alongside the image and command:

```yaml
service:
  # Your Environment, image, command, and resources go here.
  desired_size: 1
  storage:
    size_gib: 10
    mount_path: /data
    availability: shared
```

    blossom service:create --data service.yml
    blossom environment:deploy --id environment-100 --follow
    blossom service:show --id service-100

See the [Service reference](/docs/reference/cli/service/create/#persistent-services)
for the full definition.

## One Writer Per Volume

A Persistent Service runs **one Container**. Blossom stops the previous writer
before starting its replacement with the retained Volume, so updates can
briefly interrupt access. This provides durable files, not multiple writable
replicas or database failover.

For multiple web Containers, use shared external storage such as a supported
object store when the application can use it. For a supported database engine,
use a managed Database when you want its database-specific backup and recovery
features. A retained Volume alone is not an application backup.

## Grow Storage

Increase `size_gib` to grow the Volume. Its mount path and availability choice
stay fixed, and storage cannot shrink.

## Stop And Resume

Choose **Retain Volume** in Service settings to stop the writer and release
its compute reservation. This keeps **both the disabled Service and its
Volume** in the Environment. Storage charges continue.

    blossom service:delete --id service-100 --storage retain --follow
    blossom service:show --id service-100

To resume, enable the same Service. Save resume.yml:

```yaml
service:
  enabled: true
```

    blossom service:update --id service-100 --data resume.yml
    blossom service:scale --id service-100 --desired-size 1 --follow

Blossom reacquires compute, mounts the same Volume, and resumes the Service's
last successful Release. You do not need provider access or a new Service.
See [Update a Service](/docs/reference/cli/service/update/#persistent-services).

Volumes remain owned by their original Service. Creating another
Service cannot select an existing Volume or adopt its data.

## Delete Storage

Choose **Delete** to permanently remove the Service and its Volume. Deleting
the owning Environment also deletes its Persistent Services and Volumes,
including retained ones. See
[storage deletion choices](/docs/reference/cli/service/delete/).

## What You Get

Your own image, a persistent filesystem, and a managed Service lifecycle,
without installing and maintaining a separate VM by hand.
