Sha256: 8c5a4a9db29aaa4d92938272ef61e7fb6f148fec1609d5dc4100167bdd686411
Contents?: true
Size: 702 Bytes
Versions: 6
Compression:
Stored size: 702 Bytes
Contents
#!/usr/bin/env ruby require "baton/<%= config[:name] %>/<%= config[:name] %>-monitor" require 'optparse' cfg = File.expand_path("../../config/<%= config[:name] %>.cfg", __FILE__) OptionParser.new do |opt| opt.banner = "Usage: <%= config[:name] %> [OPTIONS]" opt.separator "" opt.separator "Specific options:" opt.on("-c","--config-file [PATH]", "Path to a baton config file") do |o| cfg = o end opt.on_tail("-h", "--help", "Show this message") do puts opt exit end end.parse! Baton.configure do |c| c.config_path = cfg c.exchange = "<%= config[:name] %>_in" c.exchange_out = "<%= config[:name] %>_out" end Baton::<%= config[:constant_array].last %>Monitor.run
Version data entries
6 entries across 6 versions & 1 rubygems