Skip to content

Download the latest backup using the supabase CLI #3646

Open
@kratman

Description

@kratman

Is your feature request related to a problem? Please describe.

I am working on some external backup and recovery tasks for a customer. I am currently using the supabase db dump functionality, however, it would be nicer if I could access the existing backups from the CLI. This would avoid duplicating the existing supabase backup functionality and ensure that backups are identical for the supabase dashboard interface and the fallback/replication backups needed for the project.

Describe the solution you'd like

I would like to have a supbase-cli function to get recent scheduled or PITR backups from a deployed project. Just fetching the most recent would be sufficient for my purposes, but it could also be expanded to let users pick which backup would be downloaded by the CLI

I included a couple examples below.

Fetch latest backup

supabase db backup 

Fetch Nth-previous backup

supabase db backup -n 1

List backups for the linked project

supabase db backup list

Fetch specific backup

supabase db backup -t <name_of_backup_tag_from_list>

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions