Skip to main content
A source is what a job backs up. Each job defines a sources array, and one job can combine multiple sources — for example an application database plus its upload directory — into a single archive.
snapr.yaml

Shared fields

Every source entry must set type. The remaining fields depend on the type, but a few conventions apply across all of them:

Required external tools

Most database sources shell out to the vendor’s own dump utility. snapr does not bundle these tools — they must be on PATH (or inside the snapr Docker image you build or extend). If encryption is enabled, openssl must also be on PATH.
Match the major version of pg_dump / mysqldump to the server version, otherwise the dump may fail or omit data. The official Docker image ships matching client tooling — when running outside Docker, install the client package that pairs with your server.

How remote sources are fetched

Database, S3, and bunny.net sources are pulled to the snapr host first, then archived and uploaded to the configured storages. snapr does not stream data directly from the source to the storage backend. This has practical implications:
  • The host needs free disk space at least equal to the uncompressed source size, plus headroom for the resulting archive.
  • The first run downloads everything. Object-store sources (s3, bunny) support a persistent local cache via syncPath — later runs only fetch files whose size or modification time changed. Without syncPath, every run re-downloads the full tree.
  • For very large buckets, factor in egress costs and transfer time.
snapr cleans up the working directory after the job finishes, whether it succeeds or fails. When syncPath is set, the cache directory is preserved between runs.

Source types

Local files

Files and directories on the host filesystem.

PostgreSQL

Logical dumps via pg_dump.

MySQL

Logical dumps via mysqldump.

MariaDB

mariadb-dump with a mysqldump fallback.

MongoDB

Dumps via mongodump, with optional oplog.

Redis

Live RDB snapshots or RDB file copies.

SQLite

SQL dumps of a single database file.

S3

Files from any S3-compatible bucket.

bunny.net

Files from a bunny.net Storage Zone.