mirror of
https://github.com/offen/docker-volume-backup.git
synced 2026-04-26 02:05:36 +02:00
Add test case as per #187
This commit is contained in:
28
test/order/docker-compose.yml
Normal file
28
test/order/docker-compose.yml
Normal file
@@ -0,0 +1,28 @@
|
||||
version: "3"
|
||||
|
||||
services:
|
||||
rsync:
|
||||
image: eeacms/rsync
|
||||
tty: true
|
||||
restart: unless-stopped
|
||||
labels:
|
||||
- docker-volume-backup.exec-label=order
|
||||
- docker-volume-backup.archive-pre=sh -c "rsync -aAX --ignore-missing-args --delete-missing-args /data/ /bu/"
|
||||
- docker-volume-backup.archive-post=sh -c "rm -rf /bu/*"
|
||||
volumes:
|
||||
- ./fixture:/data:ro
|
||||
- bu:/bu
|
||||
|
||||
backup:
|
||||
image: offen/docker-volume-backup:${TEST_VERSION:-canary}
|
||||
restart: always
|
||||
environment:
|
||||
BACKUP_FILENAME: backup.tar.gz
|
||||
BACKUP_EXEC_LABEL: order
|
||||
volumes:
|
||||
- bu:/backup/order:ro
|
||||
- ./local:/archive
|
||||
- /var/run/docker.sock:/var/run/docker.sock
|
||||
|
||||
volumes:
|
||||
bu:
|
||||
Reference in New Issue
Block a user