Docker Backup
Backup to local
enforce_provisioning_action
- app.toml
# Log storage directory/tmp (allow to be followed by any subdirectory)
dir = "/tmp/log/peppykeep"
# Log file name (full path:/tmp/log/peppykeep/app.log)
file_name = "app.log"
# Level: error, warn, info, debug, trace Log level is debug (output all debug information)
level = "debug"
- bak.toml
# Backup type is docker backup
bak_type = "db_and_app_data"
# Backups are also saved locally
bak_location_type = "local"
# Keep last n historical backups locally
history_bak_num = n
# Log level is debug mode (outputs the most detailed logs)
log_level = "DEBUG"
# Log storage directory/tmp (allow to be followed by any subdirectory)
log_dir = "/tmp/logs/peppykeep"
# Local backup storage home directory/tmp (allow to be followed by any subdirectory)
local_bak_home = "/tmp/backup/peppykeep"
# Local Temporary Working Directory/tmp (allows any subdirectory to follow)
local_tmp_home = "/tmp/.peppykeep_tmp"
# The maximum length of the backup queue is 1 (serial execution, no concurrency)
max_bak_queue_size = 1
# Backup Encryption Configuration
[backup_encryption]
# Turn off encryption
enabled = false
[mysql]
mysql_ip = "127.0.0.1"
mysql_port = 3306
mysql_user_name = "root"
mysql_pwd = "root"
# mysqldump tool path
mysqldump_path = "/usr/bin/mysqldump"
skip_ssl = true
docker_container_name = "ppk-mysql-test"
# Docker Command Path (for containerized backups)
docker_cmd_path = "/usr/bin/docker"
- prj.toml
# Project identifiers for relative path and directory identification
prj_key = "test_717_file"
# Local data storage directory (temporary path, configurable)
data_dir = "/tmp/test_file_717"
Perform the preliminary checks: § .
Open Terminal Execution
# docker Backup Precheck (Database + App Catalog)
peppykeep backup run --bak-type db-and-app-data --config-home ~/.peppykeep/conf
When the pre-test is successful, the output is as follows:
=== Dry Run ===
Action : backup run
Project : test_717_file
BakType : DbAndAppData
DataDir : /tmp/test_file_717
Location : Local
Encryption : false
Force : false
Next : Re-run with --apply to execute.
Result
| Field | Description |
|---|---|
Action | Type of operation performed: backup run |
Project | Identification of the currently backed up item |
BakType | DbAndAppData means that both MySQL and App Catalog in the container are backed up |
DataDir | App data directory, corresponding to data_dir of prj.toml |
Location | Storage Location |
Encryption | Whether encryption is enabled |
Force | Whether to enforce |
Next | Formal execution after adding `--apply’ |
Perform a backup
Perform a docker backup
peppykeep backup run --bak-type db-and-app-data --apply --config-home ~/.peppykeep/conf
After executing the backup command, the output on success is as follows:
=== Completed ===
Action : backup run
Project : test_717_file
BakType : DbAndAppData
DataDir : /tmp/test_file_717
Location : Local
Force : false
Artifact : /tmp/backup/peppykeep/test_717_file/test_717_file/test_717_file-bak_20260729_173824.ppke
ArtifactSize : 1.5 KiB
Status : Command completed successfully.
Result
| Field | Description |
|---|---|
Action | Type of action performed, fixed asbackup run |
Project | Identification of the currently backed up project, corresponding to prj_key in the project configuration file |
BakType | DbAndAppData — Backup both MySQL and App Catalog in the container |
DataDir | The data source directory for this backup, corresponding to data_dir in the project configuration |
Location | Storage location: • Local — store to local only• LocalAndRemote — store to both local and object storage object storage |
Force | Whether to enforce (ignore some checks or warnings), true/false |
Artifact | The full storage path of the local backup file, with the file name format {projectID} -bak_{datetime} .ppk |
Status | Execution status code: • Command completed successfully. — Backup successful• Command completed with errors. — Backup completed with errors (partial failure)• Command failed. — Backup execution failed |
Backup to Object Storage
enforce_provisioning_action
- app.toml
# Log storage directory/tmp (allow to be followed by any subdirectory)
dir = "/tmp/log/peppykeep"
# Log file name (full path:/tmp/log/peppykeep/app.log)
file_name = "app.log"
# Level: error, warn, info, debug, trace Log level is debug (output all debug information)
level = "debug"
- bak.toml (S3 as an example)
# Backup Type: Database + App Catalog (Docker Scenario)
bak_type = "db_and_app_data"
# Save backups both locally and remotely
bak_location_type = "local_and_remote"
# Keep last n historical backups locally
history_bak_num = n
# Log level is debug mode (outputs the most detailed logs)
log_level = "DEBUG"
# Log storage directory/tmp (allow to be followed by any subdirectory)
log_dir = "/tmp/my_test_peppykeep/logs"
# Local backup storage home directory/tmp (allow to be followed by any subdirectory)
local_bak_home = "/tmp/my_test_peppykeep/backup"
# Local Temporary Working Directory/tmp (allows any subdirectory to follow)
local_tmp_home = "/tmp/my_test_peppykeep/.tmp"
# The maximum length of the backup queue is 1 (serial execution, no concurrency)
max_bak_queue_size = 1
[mysql]
# docker host
mysql_ip = "192.0.2.10"
# docker port
mysql_port = 3306
# dockerusername
mysql_user_name = "remote_user"
# docker Password
mysql_pwd = "root"
# mysqldump tool path
mysqldump_path = "/usr/bin/mysqldump"
docker_container_name = "ppk-mysql-test"
# Docker Command Path (for containerized backups)
docker_cmd_path = "/usr/local/bin/docker"
# Enable Object Storage
[object_storage]
enabled = true
# Using S3 protocol (Backblaze B2 compatible)
provider = "s3"
# Bucket Name
bucket = "TestBucket"
# Object key prefix (like folder path)
prefix = "test_local"
# S3 Compatible Endpoints (Backblaze B2 + East)
endpoint = "https://s3.xxxxxxxxxxxxxx.com"
Region
region = "ca-east-006"
Access Key ID
access_key_id = "xxxxxxxxxxxxxx"
Access key
access_key_secret = "xxxxxxxxxxxxxx"
# Use path style URL (bucket/object instead of web hosting style)
path_style = true
# Backup Encryption Configuration
[backup_encryption]
# Turn off encryption
enabled = false
- prj.toml
# Project identifiers for relative path and directory identification
prj_key = "test_717_file"
# Local data storage directory (temporary path, configurable)
data_dir = "/tmp/test_data"
Perform the preliminary checks: § .
Open Terminal Execution
# docker Backup Precheck (Database + App Catalog)
peppykeep backup run --bak-type db-and-app-data --config-home ~/.peppykeep/conf
When the pre-test is successful, the output is as follows:
=== Dry Run ===
Action : backup run
Project : test_717_file
BakType : DbAndAppData
DataDir : /tmp/test_data
Location : LocalAndRemote
Encryption : false
Force : false
Next : Re-run with --apply to execute.
Result
| Field | Description |
|---|---|
Action | Type of operation performed: backup run |
Project | Identification of the currently backed up item |
BakType | DbAndAppData means that both MySQL and App Catalog in the container are backed up |
DataDir | App Data Catalog |
Location | LocalAndRemote means local and object storage |
Encryption | Whether encryption is enabled |
Force | Whether to enforce |
Next | Formal execution after adding `--apply’ |
Perform a backup
Perform a docker backup
peppykeep backup run --bak-type db-and-app-data --apply --config-home ~/.peppykeep/conf
After executing the backup command, the output on success is as follows:
=== Completed ===
Action : backup run
Project : test_717_file
BakType : DbAndAppData
DataDir : /tmp/test_file_717
Location : LocalAndRemote
Force : false
Artifact : /tmp/backup/peppykeep/test_717_file/test_717_file/test_717_file-bak_20260729_174638.ppke
ArtifactSize : 1.5 KiB
Bucket : VoosTestBucket
RemoteKey : test_717_file/test_717_file-bak_20260729_174638.ppke
Provider : s3
Target : s3://VoosTestBucket/test_717_file/test_717_file-bak_20260729_174638.ppke
LocalCleanup : applied
Status : Command completed successfully.
Result
| Field | Description |
|---|---|
Action | Type of operation performed: backup run |
Project | Item identifier currently backed up: test_717_file |
BakType | DbAndAppData — Backup both MySQL and App Catalog in the container |
DataDir | App Data Catalog |
Location | LocalAndRemote |
Force | Whether to enforce |
Artifact | Local Backup Product Path |
Bucket | Object Storage Bucket Name: VoosTestBucket |
RemoteKey | Object store stored file key-value path: test_local_voos/test_717_file/test_717_file-bak_20260702_104919.ppk |
Provider | Object storage storage provider: s3 |
Target | Object store full destination address: s3://VoosTestBucket/test_local_voos/test_717_file/test_717_file-bak_20260702_104919.ppk |
LocalCleanup | Local cleanup status: applied (executed) |
Status | Execution Status: Command completed successfully. (Command executed successfully) |