yapf
This commit is contained in:
parent
4853634c2f
commit
7b1dfbb256
4 changed files with 14 additions and 8 deletions
|
@ -2,7 +2,6 @@ import logging
|
|||
from app import build_logs, storage
|
||||
from health.models_pre_oci import pre_oci_model as model
|
||||
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
|
||||
|
||||
|
@ -27,14 +26,17 @@ def _check_registry_gunicorn(app):
|
|||
logger.exception('Exception when checking registry health: %s', registry_url)
|
||||
return False
|
||||
|
||||
|
||||
def _check_database(app):
|
||||
""" Returns the status of the database, as accessed from this instance. """
|
||||
return model.check_health(app.config)
|
||||
|
||||
|
||||
def _check_redis(app):
|
||||
""" Returns the status of Redis, as accessed from this instance. """
|
||||
return build_logs.check_health()
|
||||
|
||||
|
||||
def _check_storage(app):
|
||||
""" Returns the status of storage, as accessed from this instance. """
|
||||
try:
|
||||
|
|
Reference in a new issue