diff --git a/aim/digifeeds/database/migrations/env.py b/aim/digifeeds/database/migrations/env.py index aa2ba63..8a0214c 100644 --- a/aim/digifeeds/database/migrations/env.py +++ b/aim/digifeeds/database/migrations/env.py @@ -13,7 +13,11 @@ config = context.config # Set url from environment variable -config.set_main_option("sqlalchemy.url", S.mysql_database) +config.set_main_option( + "sqlalchemy.url", + # This is for handling passwords with special characters + S.mysql_database.render_as_string(hide_password=False).replace("%", "%%"), +) # Interpret the config file for Python logging. # This line sets up loggers basically. diff --git a/compose.yml b/compose.yml index 21a1ba6..2d47e0a 100644 --- a/compose.yml +++ b/compose.yml @@ -28,7 +28,7 @@ services: environment: - MARIADB_ROOT_PASSWORD=password - MARIADB_USER=user - - MARIADB_PASSWORD=password + - MARIADB_PASSWORD=test@123 - MARIADB_DATABASE=database volumes: diff --git a/env.development b/env.development index 94a9fe6..c43068a 100644 --- a/env.development +++ b/env.development @@ -1,5 +1,5 @@ MARIADB_ROOT_PASSWORD=password MARIADB_USER=user -MARIADB_PASSWORD=password +MARIADB_PASSWORD=test@123 MARIADB_DATABASE=database DATABASE_HOST=database