From f0a1b3e7424d744bd750067cec2f2d66ced6abc6 Mon Sep 17 00:00:00 2001 From: "Kevin Veen-Birkenbach [aka. Frantz]" Date: Mon, 28 Mar 2022 16:39:37 +0200 Subject: [PATCH] changed whitespaces and typos --- docker-volume-backup.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docker-volume-backup.py b/docker-volume-backup.py index 3bb8859..3c6e588 100644 --- a/docker-volume-backup.py +++ b/docker-volume-backup.py @@ -63,15 +63,15 @@ for volume_name in volume_names: sql_cp_destination_path = current_version_dir_path + "/sql" sql_destination_dir_file_path = sql_cp_destination_path + "/backup.sql" pathlib.Path(sql_cp_destination_path).mkdir(parents=True, exist_ok=True) - database_entry=databases_entries.iloc[0] + database_entry = databases_entries.iloc[0] database_backup_command="docker exec "+ database_entry["container"] + " /usr/bin/mysqldump -u "+ database_entry["username"] + " -p"+ database_entry["password"] + " "+ database_entry["database"] + " > " + sql_destination_dir_file_path print_bash(database_backup_command) else: print("Backup files...") - files_rsync_destination_path=destination_path + "/files" + files_rsync_destination_path = destination_path + "/files" pathlib.Path(files_rsync_destination_path).mkdir(parents=True, exist_ok=True) print("Backup data during container is running...") - rsync_command="rsync -abP --delete --delete-excluded --log-file=" + log_path +" --backup-dir=" + files_version_dir_path +" '"+ source_path +"/' " + files_rsync_destination_path + rsync_command = "rsync -abP --delete --delete-excluded --log-file=" + log_path +" --backup-dir=" + files_version_dir_path +" '"+ source_path +"/' " + files_rsync_destination_path print_bash(rsync_command) print("stop containers...") print("Backup data after container is stopped...")