Added maintenance option to technician settings #424
All checks were successful
Deploy dev on push / on-push-deploy_sh-edraft (push) Successful in 4m20s
All checks were successful
Deploy dev on push / on-push-deploy_sh-edraft (push) Successful in 4m20s
This commit is contained in:
@@ -8,6 +8,7 @@ from cpl_core.logging import LoggerABC
|
||||
|
||||
from bot_core.configuration.feature_flags_enum import FeatureFlagsEnum
|
||||
from bot_core.configuration.feature_flags_settings import FeatureFlagsSettings
|
||||
from bot_core.environment_variables import MIGRATION_ONLY
|
||||
from bot_core.logging.database_logger import DatabaseLogger
|
||||
from bot_data.service.migration_service import MigrationService
|
||||
|
||||
@@ -25,6 +26,6 @@ class DatabaseExtension(ApplicationExtensionABC):
|
||||
config.add_configuration("Database_StartTime", str(datetime.now()))
|
||||
migrations: MigrationService = services.get_service(MigrationService)
|
||||
migrations.migrate()
|
||||
if config.get_configuration("MIGRATION_ONLY"):
|
||||
if config.get_configuration(MIGRATION_ONLY):
|
||||
logger.warn(__name__, "Migrations finished. Stopping application...")
|
||||
sys.exit()
|
||||
|
Reference in New Issue
Block a user