Fix - misnamed method call
Method get_deckhand_validation_status was miss-addressing _get_deckhand_validation_errors vs _get_deckhand_validations which was recently renamed. Updates the drydock operator to use an auth_gen mehtod to generate authorization headers instead of a direct passing of auth token. Change-Id: I1647cde004d2d111b15abc9e5d69413568ad7b34
This commit is contained in:
parent
258449d688
commit
102150a72d
@ -565,7 +565,7 @@ class ConfigdocsHelper(object):
|
||||
|
||||
Returns the status object representing the deckhand validation results
|
||||
"""
|
||||
dh_validations = self._get_deckhand_validations(revision_id)
|
||||
dh_validations = self._get_deckhand_validation_errors(revision_id)
|
||||
error_count = len(dh_validations)
|
||||
return ConfigdocsHelper._format_validations_to_status(
|
||||
dh_validations, error_count)
|
||||
|
@ -231,6 +231,11 @@ class DryDockOperator(BaseOperator):
|
||||
logging.info('No Action to Perform')
|
||||
|
||||
@shipyard_service_token
|
||||
def _auth_gen(self):
|
||||
# Generator method for the Drydock Session to use to get the
|
||||
# auth headers necessary
|
||||
return [('X-Auth-Token', self.svc_token)]
|
||||
|
||||
def drydock_session_client(self, drydock_svc_endpoint):
|
||||
# Initialize Variables
|
||||
drydock_url = None
|
||||
@ -245,7 +250,7 @@ class DryDockOperator(BaseOperator):
|
||||
logging.info("Build DryDock Session")
|
||||
dd_session = session.DrydockSession(drydock_url.hostname,
|
||||
port=drydock_url.port,
|
||||
token=self.svc_token)
|
||||
auth_gen=self._auth_gen())
|
||||
|
||||
# Raise Exception if we are not able to get a drydock session
|
||||
if dd_session:
|
||||
|
Loading…
x
Reference in New Issue
Block a user