chore: add log for ssh tunnel information (#24058)

This commit is contained in:
Hugh A. Miles II 2023-05-15 13:43:04 -04:00 committed by GitHub
parent 2f33c477e9
commit de96372ba7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 6 additions and 1 deletions

View File

@ -404,7 +404,12 @@ class Database(
)
with engine_context as server_context:
if ssh_tunnel:
if ssh_tunnel and server_context:
logger.info(
"[SSH] Successfully create tunnel at %s: %s",
server_context.local_bind_address,
server_context.local_bind_port,
)
sqlalchemy_uri = ssh_manager_factory.instance.build_sqla_url(
sqlalchemy_uri, server_context
)