mirror of
https://github.com/xcat2/confluent.git
synced 2026-10-06 17:46:57 +00:00
Fix error propogation on manual discovery
Manual discovery needs to give the user, not the log info about the failure.
This commit is contained in:
@@ -757,6 +757,8 @@ def discover_node(cfg, handler, info, nodename, manual):
|
||||
handler.config(nodename)
|
||||
except Exception as e:
|
||||
info['discofailure'] = 'bug'
|
||||
if manual:
|
||||
raise
|
||||
log.log(
|
||||
{'error':
|
||||
'Error encountered trying to set up {0}, {1}'.format(
|
||||
|
||||
@@ -91,7 +91,8 @@ class NodeHandler(generic.NodeHandler):
|
||||
if ('secret.hardwaremanagementuser' not in cd or
|
||||
'secret.hardwaremanagementpassword' not in cd):
|
||||
raise exc.TargetEndpointBadCredentials(
|
||||
'Missing user and/or password')
|
||||
'secret.hardwaremanagementuser and/or '
|
||||
'secret.hardwaremanagementpassword was not configured')
|
||||
if ('hardwaremanagement.manager' in cd and
|
||||
cd['hardwaremanagement.manager']['value'] and
|
||||
not cd['hardwaremanagement.manager']['value'].startswith(
|
||||
|
||||
Reference in New Issue
Block a user