Method: Runpuppet::Config.config

Defined in:
lib/runpuppet.rb

.configObject



90
91
92
93
94
95
96
# File 'lib/runpuppet.rb', line 90

def self.config
  home = File.expand_path('~')
  ["#{home}/.runpuppet.yml", '/etc/runpuppet.yml'].each do |file|
    return YAML.load(File.read(file)) if File.exist?(file)
  end
  raise "No runpuppet.yml found in /etc or #{home}"
end