mirror of
https://github.com/tiredofit/docker-db-backup.git
synced 2025-12-21 13:23:12 +01:00
Version 4.0.x examples
This commit is contained in:
@@ -1,13 +1,7 @@
|
||||
#
|
||||
#
|
||||
# Example for Microsoft SQL Server
|
||||
# upload with blobxfer to azure storage
|
||||
#
|
||||
|
||||
version: '2'
|
||||
|
||||
networks:
|
||||
example-mssql-blobxfer-net:
|
||||
name: example-mssql-blobxfer-net
|
||||
#
|
||||
|
||||
services:
|
||||
example-mssql-s3-db:
|
||||
@@ -32,7 +26,7 @@ services:
|
||||
# execute in terminal --> docker build -t tiredofit/db-backup-mssql-blobxfer .
|
||||
# replace --> image: tiredofit/db-backup-mssql
|
||||
# image: tiredofit/db-backup
|
||||
image: tiredofit/db-backup-mssql-blobxfer
|
||||
image: tiredofit/db-backup
|
||||
links:
|
||||
- example-mssql-s3-db
|
||||
volumes:
|
||||
@@ -40,30 +34,35 @@ services:
|
||||
- ./tmp/backups:/tmp/backups # shared tmp backup directory
|
||||
#- ./post-script.sh:/assets/custom-scripts/post-script.sh
|
||||
environment:
|
||||
# - DEBUG_MODE=TRUE
|
||||
- DB_TYPE=mssql
|
||||
- DB_HOST=example-db-host
|
||||
# - DB_PORT=1488
|
||||
# - DB_NAME=ALL # [ALL] not working on sql server.
|
||||
# create database with name `test1` manually first
|
||||
- DB_NAME=test1 # Create this database
|
||||
- DB_USER=sa
|
||||
- DB_PASS=5hQa0utRFBpIY3yhoIyE
|
||||
- DB_DUMP_FREQ=1 # backup every 5 minute
|
||||
# - DB_DUMP_BEGIN=0000 # backup starts immediately
|
||||
- DB_CLEANUP_TIME=3 # clean backups they are older than 60 minutes
|
||||
- ENABLE_CHECKSUM=TRUE
|
||||
- CHECKSUM=SHA1
|
||||
- COMPRESSION=GZ
|
||||
- SPLIT_DB=FALSE
|
||||
- TIMEZONE=America/Vancouver
|
||||
- CONTAINER_ENABLE_MONITORING=FALSE
|
||||
- CONTAINER_NAME=example-mssql-blobxfer-db-backup
|
||||
# - DEBUG_MODE=TRUE
|
||||
- DB01_TYPE=mssql
|
||||
- DB01_HOST=example-db-host
|
||||
# - DB01_PORT=1488
|
||||
# create database with name `test1` manually first
|
||||
- DB01_NAME=test1 # Create this database
|
||||
- DB01_USER=sa
|
||||
- DB01_PASS=5hQa0utRFBpIY3yhoIyE
|
||||
- DB01_DUMP_INTERVAL=5 # backup every 5 minute
|
||||
# - DB01_DUMP_BEGIN=0000 # backup starts at midnight vs not set immediately
|
||||
- DB01_CLEANUP_TIME=60 # clean backups they are older than 60 minutes
|
||||
- DB01_CHECKSUM=SHA1 # Set Checksum to be SHA1
|
||||
- DB01_COMPRESSION=GZ # Set compression to use GZIP
|
||||
|
||||
|
||||
# === S3 Blobxfer ===
|
||||
- BACKUP_LOCATION=blobxfer
|
||||
- DB01_BACKUP_LOCATION=blobxfer
|
||||
# Add here azure storage account
|
||||
- BLOBXFER_STORAGE_ACCOUNT={TODO Add Storage Name}
|
||||
- DB01_BLOBXFER_STORAGE_ACCOUNT={TODO Add Storage Name}
|
||||
# Add here azure storage account key
|
||||
- BLOBXFER_STORAGE_ACCOUNT_KEY={TODO Add Key}
|
||||
- BLOBXFER_REMOTE_PATH=docker-db-backup
|
||||
- SB01_BLOBXFER_STORAGE_ACCOUNT_KEY={TODO Add Key}
|
||||
- DB01_BLOBXFER_REMOTE_PATH=docker-db-backup
|
||||
restart: always
|
||||
networks:
|
||||
example-mssql-blobxfer-net:
|
||||
example-mssql-blobxfer-net:
|
||||
|
||||
networks:
|
||||
example-mssql-blobxfer-net:
|
||||
name: example-mssql-blobxfer-net
|
||||
Reference in New Issue
Block a user