281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
|
# File 'lib/confctl/cli/cluster.rb', line 281
def ssh
machines = select_machines_with_managed(args[0]).runnable
raise 'No machines to ssh to' if machines.empty?
if opts['input-string'] && opts['input-file']
raise GLI::BadCommandLine, 'use one of --input-string or --input-file'
end
if args.length == 1
raise GLI::BadCommandLine, 'missing command' unless machines.length == 1
run_ssh_interactive(machines)
return
end
run_ssh_command(machines, args[1..])
end
|