From caf78a82be4e536099f6ce2f7fd7d7f4c459f1b0 Mon Sep 17 00:00:00 2001 From: "Kevin Veen-Birkenbach [aka. Frantz]" Date: Mon, 4 Apr 2022 11:34:42 +0200 Subject: [PATCH] Changed regex condition --- docker-volume-backup.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docker-volume-backup.py b/docker-volume-backup.py index c8e0232..3dfc032 100644 --- a/docker-volume-backup.py +++ b/docker-volume-backup.py @@ -74,7 +74,7 @@ for volume_name in volume_names: # Folder to which the volumes are copied volume_destination_dir = version_dir + volume_name # Database name - database_name = re.split("_|-", container)[0] + database_name = re.split("(_|-)(database|db)", container)[0] # Entries with database login data concerning this container databases_entries = databases.loc[databases['database'] == database_name] if len(databases_entries) == 1: