This commit is contained in:
John Lancaster
2024-02-19 23:10:02 -06:00
parent 3c89fe22bc
commit b368cede93
6 changed files with 153 additions and 35 deletions

View File

@@ -1,26 +1,27 @@
version: '3.9'
services:
autorestic:
image: cupcakearmy/autorestic:latest
env_file:
- .env
restic:
image: restic/restic:latest
hostname: gitea
environment:
- RESTIC_REPOSITORY=/repo
- RESTIC_PASSWORD=${RESTIC_PASSWORD}
volumes:
- .autorestic.yaml:/.autorestic.yaml
- ../:/source:ro
- backups:/backups
- /var/run/docker.sock:/var/run/docker.sock
command: [
"autorestic",
"backup",
"-va",
"-c", "/.autorestic.yaml"
]
- ../gitea/data:/data:ro
- restic_repo:/repo
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
command: backup /data --dry-run
volumes:
backups:
restic_repo:
driver: local
driver_opts:
type: none
o: bind
device: /mnt/backups
device: ${RESTIC_REPOSITORY}
secrets:
restic-pw:
environment: RESTIC_PASSWORD