diff --git a/backend/app/services/scheduler/schedule_account.py b/backend/app/services/scheduler/schedule_account.py index f32d581..21306de 100644 --- a/backend/app/services/scheduler/schedule_account.py +++ b/backend/app/services/scheduler/schedule_account.py @@ -29,7 +29,7 @@ def run_account_check(schedule_log_id: int, db: Session): for account in accounts: tenant = account.tenant - realm = tenant.keycloak_realm or tenant.code + realm = tenant.code result = AccountScheduleResult( schedule_log_id=schedule_log_id, account_id=account.id, @@ -149,8 +149,8 @@ def run_account_check(schedule_log_id: int, db: Session): f"docker exec -u www-data {nc_container} " f"php /var/www/html/occ mail:account:create " f"'{account.sso_account}' '{display}' '{email}' " - f"10.1.0.254 143 none '{email}' '{account.default_password}' " - f"10.1.0.254 587 none '{email}' '{account.default_password}' 2>&1" + f"mailserver 143 starttls '{email}' '{account.default_password}' " + f"mailserver 587 starttls '{email}' '{account.default_password}' 2>&1" ) out_text = _ssh_run(create_cmd) logger.info(f"NC mail:account:create [{account.sso_account}]: {out_text}")