Implemented storage optimizer for mongodb

This commit is contained in:
Kevin Veen-Birkenbach 2024-01-13 16:52:36 +01:00
parent 7745105a23
commit 309aaed37e

View File

@ -25,8 +25,11 @@ def start_containers(containers):
run_command(f"docker start {container_list}") run_command(f"docker start {container_list}")
def is_database(image): def is_database(image):
databases = {"postgres", "mariadb", "redis", "memcached"} databases = {"postgres", "mariadb", "redis", "memcached", "mongo"}
return any(database in image for database in databases) # Split the string at the colon and take the first part
prefix = image.split(':')[0]
# Check if the prefix is in the database names
return prefix in databases
def is_symbolic_link(file_path): def is_symbolic_link(file_path):
return os.path.islink(file_path) return os.path.islink(file_path)