Module: ConsulApplicationSettings

Defined in:
lib/consul_application_settings.rb,
lib/consul_application_settings/utils.rb,
lib/consul_application_settings/reader.rb,
lib/consul_application_settings/version.rb,
lib/consul_application_settings/configuration.rb,
lib/consul_application_settings/resolvers/env.rb,
lib/consul_application_settings/resolvers/erb.rb,
lib/consul_application_settings/providers/consul.rb,
lib/consul_application_settings/providers/abstract.rb,
lib/consul_application_settings/resolvers/abstract.rb,
lib/consul_application_settings/providers/local_storage.rb,
lib/consul_application_settings/providers/consul_preloaded.rb

Overview

The gem provides possibility to load settings from Consul and automatically fall back to data stored in file system

Defined Under Namespace

Modules: Providers, Resolvers, Utils Classes: Configuration, Error, Reader

Constant Summary collapse

VERSION =
'4.0.0'.freeze

Class Attribute Summary collapse

Class Method Summary collapse

Class Attribute Details

.configObject

Returns the value of attribute config.



18
19
20
# File 'lib/consul_application_settings.rb', line 18

def config
  @config
end

Class Method Details

.configure {|config| ... } ⇒ Object

Yields:



23
24
25
# File 'lib/consul_application_settings.rb', line 23

def self.configure
  yield(config)
end

.load(path = '') ⇒ Object



27
28
29
# File 'lib/consul_application_settings.rb', line 27

def self.load(path = '')
  Reader.new(path, config)
end