Protect your critical data with a modern, fast, and secure backup utility designed for simplicity and reliability. Operating as a single executable, it requires no complex server setup and runs seamlessly across Linux, BSD, macOS, and Windows.
You can back up your files to a wide variety of storage backends, including self-hosted servers and popular online cloud services. It is highly efficient, utilizing advanced deduplication to transfer only the parts of your files that have actually changed, saving both bandwidth and storage space.
Key benefits include:
services:
restic:
image: restic/restic:latest
hostname: restic-docker
environment:
- RESTIC_REPOSITORY=${RESTIC_REPOSITORY}
- RESTIC_PASSWORD=${RESTIC_PASSWORD}
# Uncomment and set these if using S3/Minio backends
# - AWS_ACCESS_KEY_ID=${AWS_ACCESS_KEY_ID}
# - AWS_SECRET_ACCESS_KEY=${AWS_SECRET_ACCESS_KEY}
# - AWS_DEFAULT_REGION=${AWS_DEFAULT_REGION}
volumes:
- ./data:/data:ro
- ./repo:/repo
# Default command checks version.
# Initialize repo: docker compose run --rm restic init
# Run backup: docker compose run --rm restic backup /data
command: versionRESTIC_REPOSITORY=/repo
RESTIC_PASSWORD=change_this_to_a_strong_password
# Optional: Cloud Provider Credentials
# AWS_ACCESS_KEY_ID=your_access_key
# AWS_SECRET_ACCESS_KEY=your_secret_key
# AWS_DEFAULT_REGION=us-east-1Auto-fetched 10 minutes ago
Auto-fetched 10 minutes ago