Sha256: 4b0c2dce7bc76d4b3f882c71eb774bb953467b38c26f72861b208a1e79ba8c7f
Contents?: true
Size: 542 Bytes
Versions: 11
Compression:
Stored size: 542 Bytes
Contents
#!/usr/bin/env ruby require 'optparse' require 'ostruct' exec('mandy-kill -h') unless ARGV.size >= 1 options = OpenStruct.new OptionParser.new do |opts| opts.banner = "USAGE: mandy-kill job [options]" opts.on("-c", "--conf HADOOP_CONF", "Use this cluster xml config file.") do |config| options.config = config end opts.on_tail("-h", "--help", "Show this message") do puts opts exit end end.parse! job = ARGV[0] config = options.config || 'cluster.xml' `$HADOOP_HOME/bin/hadoop job -conf #{config} -kill #{job}`
Version data entries
11 entries across 11 versions & 1 rubygems