mirror of
https://github.com/kemko/nomad.git
synced 2026-01-04 01:15:43 +03:00
Multiple matched objects now treated as an error condition.
This commit is contained in:
@@ -231,8 +231,8 @@ func (c *NodeStatusCommand) Run(args []string) int {
|
||||
node.Status)
|
||||
}
|
||||
// Dump the output
|
||||
c.Ui.Output(fmt.Sprintf("Prefix matched multiple nodes\n\n%s", formatList(out)))
|
||||
return 0
|
||||
c.Ui.Error(fmt.Sprintf("Prefix matched multiple nodes\n\n%s", formatList(out)))
|
||||
return 1
|
||||
}
|
||||
// Prefix lookup matched a single node
|
||||
node, _, err := client.Nodes().Info(nodes[0].ID, nil)
|
||||
|
||||
Reference in New Issue
Block a user