Skip to content
Snippets Groups Projects
Commit e00ea635 authored by Michael Hanselmann's avatar Michael Hanselmann
Browse files

Convert gnt-cluster

Replace ssconf with configuration.

Reviewed-by: iustinp
parent d23ef431
No related branches found
No related tags found
No related merge requests found
......@@ -127,8 +127,7 @@ def ShowClusterMaster(opts, args):
opts - class with options as members
"""
sstore = ssconf.SimpleStore()
print sstore.GetMasterNode()
print GetClient().QueryConfigValues(["master_node"])[0]
return 0
......@@ -172,6 +171,8 @@ def ClusterCopyFile(opts, args):
op = opcodes.OpQueryNodes(output_fields=["name"], names=opts.nodes)
results = [row[0] for row in SubmitOpCode(op) if row[0] != myname]
# TODO: Potential inconsistency between local node and master
srun = ssh.SshRunner(cfg)
for node in results:
if not srun.CopyFileToNode(node, filename):
......@@ -198,8 +199,8 @@ def RunClusterCommand(opts, args):
op = opcodes.OpQueryNodes(output_fields=["name"], names=opts.nodes)
nodes = [row[0] for row in SubmitOpCode(op)]
sstore = ssconf.SimpleStore()
master_node = sstore.GetMasterNode()
# TODO: Potential inconsistency between local node and master
master_node = cfg.GetMasterNode()
srun = ssh.SshRunner(cfg)
# Make sure master node is at list end
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment