mirror of
https://github.com/offen/docker-volume-backup.git
synced 2024-11-22 13:20:29 +01:00
run cli test using BACKUP_FROM_SNAPSHOT
This commit is contained in:
parent
411c39ee72
commit
3c06bf8102
@ -126,10 +126,10 @@ You can populate below template according to your requirements and use it as you
|
|||||||
|
|
||||||
# BACKUP_LATEST_SYMLINK="backup.latest.tar.gz"
|
# BACKUP_LATEST_SYMLINK="backup.latest.tar.gz"
|
||||||
|
|
||||||
# Wehter to copy the content of backup folder before creating archive.
|
# Whether to copy the content of backup folder before creating the tar archive.
|
||||||
# In rare scenario where the content of the source backup volume is still
|
# In the rare scenario where the content of the source backup volume is continously
|
||||||
# updating, but we do not wish to stop the container while performing backup,
|
# updating, but we do not wish to stop the container while performing the backup,
|
||||||
# this snapshot before archive ensures the integrity of the tar.gz file.
|
# this setting can be used to ensure the integrity of the tar.gz file.
|
||||||
|
|
||||||
# BACKUP_FROM_SNAPSHOT="false"
|
# BACKUP_FROM_SNAPSHOT="false"
|
||||||
|
|
||||||
|
@ -23,7 +23,6 @@ docker exec minio mkdir -p /data/backup
|
|||||||
docker run -d \
|
docker run -d \
|
||||||
--name offen \
|
--name offen \
|
||||||
--network test_network \
|
--network test_network \
|
||||||
--label "docker-volume-backup.stop-during-backup=true" \
|
|
||||||
-v app_data:/var/opt/offen/ \
|
-v app_data:/var/opt/offen/ \
|
||||||
offen/offen:latest
|
offen/offen:latest
|
||||||
|
|
||||||
@ -39,6 +38,7 @@ docker run --rm \
|
|||||||
--env AWS_ENDPOINT_PROTO=http \
|
--env AWS_ENDPOINT_PROTO=http \
|
||||||
--env AWS_S3_BUCKET_NAME=backup \
|
--env AWS_S3_BUCKET_NAME=backup \
|
||||||
--env BACKUP_FILENAME=test.tar.gz \
|
--env BACKUP_FILENAME=test.tar.gz \
|
||||||
|
--env "BACKUP_FROM_SNAPSHOT=true" \
|
||||||
--entrypoint backup \
|
--entrypoint backup \
|
||||||
offen/docker-volume-backup:$TEST_VERSION
|
offen/docker-volume-backup:$TEST_VERSION
|
||||||
|
|
||||||
@ -56,6 +56,6 @@ fi
|
|||||||
|
|
||||||
echo "[TEST:PASS] All containers running post backup."
|
echo "[TEST:PASS] All containers running post backup."
|
||||||
|
|
||||||
docker rm $(docker stop minio offen backup)
|
docker rm $(docker stop minio offen)
|
||||||
docker volume rm backup_data app_data
|
docker volume rm backup_data app_data
|
||||||
docker network rm test_network
|
docker network rm test_network
|
||||||
|
Loading…
Reference in New Issue
Block a user