Commit 8a293708 by Bach Dániel

vm: fix UpdateNodeOperation

parent 1d852711
......@@ -1195,7 +1195,8 @@ class DisableOperation(NodeOperation):
class UpdateNodeOperation(NodeOperation):
id = 'update_node'
name = _("update node")
description = _("Update node.")
description = _("Upgrade or install node software (vmdriver, agentdriver, "
"monitor-client) with Salt.")
required_perms = ()
online_required = False
async_queue = ""
......@@ -1204,13 +1205,20 @@ class UpdateNodeOperation(NodeOperation):
name =
client = LocalClient()
data = client.cmd(
name, module, timeout=timeout, kwarg={'mods': params})
name, module, params, timeout=timeout)
return data[name]
data = data[name]
except KeyError:
raise HumanReadableException.create(ugettext_noop(
"No minions matched the target."))
if not isinstance(data, dict):
raise HumanReadableException.create(ugettext_noop(
"Unhandled exception: %(msg)s"), msg=unicode(data))
return data
def _operation(self, activity):
with activity.sub_activity(
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment