Skip to content

Latest commit

 

History

History
92 lines (72 loc) · 4.69 KB

File metadata and controls

92 lines (72 loc) · 4.69 KB

Simple Backup Container Image

Build Status Docker Pulls Docker Stars

Docker Images

Backup is Wodby software with its own semantic product versions. Use matching Git and Docker tags such as wodby/backup:X.Y.Z to select a release. Patch releases contain compatible fixes, minor releases add compatible features, and major releases introduce incompatible changes.

The previously published r0 tag remains available. Future releases continue the existing 2.x version series. See release tags for available versions. latest follows the default branch.

Overview:

Supported tags and respective Dockerfile links:

The image updater checks the Alpine base daily. A new published wodby/alpine:3-rN revision produces a Backup patch release, including revisions with package security fixes. Its release notes describe the parent changes. Digest-only changes rebuild latest without creating a product release. The release image is tested against the exact pinned parent before its Docker tag and GitHub Release are published. Backup keeps its own product versions.

Actions

Usage:

make COMMAND [params ...]
 
commands:
    backup-dir dir filepath [gzip exclude mark]
    rotate dir [days] 
    upload provider filepath bucket [destination max_concurrent_requests max_bandwidth storage_class content_disposition region endpoint_url]
    backup-and-upload provider dir bucket destination [gzip max_concurrent_requests max_bandwidth storage_class content_disposition region endpoint_url]
    delete filepath 
    import source destination [owner group allowed delete] 

default param values:
    days 7
    max_concurrent_requests 1
    max_bandwidth

Notes:
* pass credentials through container environment variables instead of `key` and `secret` make arguments:
  * AWS and S3-compatible: `AWS_ACCESS_KEY_ID`, `AWS_SECRET_ACCESS_KEY`, and optional `AWS_SESSION_TOKEN`
  * GCP: `GOOGLE_APPLICATION_CREDENTIALS` for a mounted service-account file, or `GCP_SA` for its base64-encoded contents
  * Azure: `AZURE_STORAGE_ACCOUNT` and `AZURE_STORAGE_KEY`
* the legacy `key` and `secret` make arguments remain supported for compatibility, but can expose credentials through process arguments
* `provider=aws` uses the AWS CLI S3 flow and defaults `storage_class` to `STANDARD`
* `provider=azure` uses `rclone` Azure Blob upload, where `bucket` is the container name and `storage_class` maps to the Azure access tier (`hot`, `cool`, `cold`, `archive`)
* `provider=azure` accepts `AZURE_STORAGE_ENDPOINT` or `endpoint_url` for custom Blob endpoints such as Azurite
* any non-`aws`, non-`gcp` provider is treated as S3-compatible and requires `endpoint_url`
* S3 uploads use AWS CLI `path` addressing style for broader compatibility

Streaming backups to S3

backup-and-upload-stream and stream-upload use 64 MiB multipart chunks for AWS S3, DigitalOcean Spaces, Cloudflare R2, and Backblaze B2. With S3's 10,000-part limit, this permits streams up to 625 GiB, subject to the storage provider's own limits. Unknown-length streams cannot automatically increase their chunk size.

For larger archives, set the container environment variable RCLONE_S3_CHUNK_SIZE, for example 128Mi for a 1,250 GiB multipart ceiling. Choose a chunk size with headroom for archive growth. Upload buffering uses approximately the chunk size multiplied by max_concurrent_requests (default one), in addition to the backup process's other memory needs. Retrying an upload that exhausted its parts requires increasing the chunk size first.

Building with pinned base images

Build with the Makefile to use the base image digests in base-images.mk. Local builds and CI resolve the same version and variant to the same multi-platform image. Floating builds use the pinned wodby/alpine:3 image. To build a product release, set RELEASE_VERSION and BASE_IMAGE_REVISION; the latter selects a reviewed 3-rN pin. Missing parent revisions or pins fail before the build starts.

When adding a supported base version or variant, add its image index digest to base-images.mk. For a custom build, override BASE_IMAGE with a complete repository:tag@sha256:... reference.