Skip to content

Backup your Cloudflare zones with Borg and Borgmatic

Notifications You must be signed in to change notification settings

clevyr/docker-cloudflare-borgmatic

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

52 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

docker-cloudflare-borgmatic

Docker Build

Backup every Cloudflare zone with Borg and Borgmatic.

Pull Command

docker pull ghcr.io/clevyr/cloudflare-borgmatic

Config

Cloudflare Authentication

Each zone is exported by flarectl. To authenticate into Cloudflare, generate an API token with Zone:Read and DNS:Read permission.

Variable Description
CF_API_TOKEN Cloudflare API token

Borgmatic

All Borg environment variables are supported.

Your Borgmatic config should be volume bound to /etc/borgmatic/config.yaml

Example Borgmatic config:

repositories:
  - path: /out/borg # Borg repo goes here
    label: example
source_directories:
  - /data
archive_name_format: "cloudflare-{now:%Y-%m-%d-%H%M%S}"
keep_hourly: 168
keep_daily: 31
keep_monthly: 24
keep_yearly: 2
check_last: 3