class Consul::Template::Generator::Configuration

Attributes

client_options[RW]
consul_host[RW]
consul_template_binary[RW]
diff_changes[RW]
graphite_host[RW]
graphite_paths[RW]
log_level[RW]
logger[RW]
node[RW]
session_key[RW]
session_ttl[RW]
templates[RW]

Public Class Methods

new() click to toggle source
# File lib/consul/template/generator/configuration.rb, line 45
def initialize
  @log_level = :debug
  @node = nil
  @consul_host = nil
  @templates = {}
  @graphite_paths = {}
  @session_key = 'consul-template-generator'
  @session_ttl = 30
  @client_options = {}
  @logger = Consul::Template::Generator::STDLogger
  @graphite_host = nil
  @diff_changes = false

  STDOUT.sync = true
  STDERR.sync = true
end

Public Instance Methods

lock_key(key) click to toggle source
# File lib/consul/template/generator/configuration.rb, line 62
def lock_key(key)
  "lock/#{key.sub(/^\//, '')}"
end
session_lock_key() click to toggle source
# File lib/consul/template/generator/configuration.rb, line 66
def session_lock_key
  @session_key
end
session_name() click to toggle source
# File lib/consul/template/generator/configuration.rb, line 70
def session_name
  @session_key.split('/')[-1]
end