default devops_dir
This commit is contained in:
parent
62f6e8cb4c
commit
efec7d914a
@ -11,13 +11,15 @@ class DevopsConfig
|
||||
if config_file.nil?
|
||||
config_file = ENV['DEVOPS_CONFIG'] || ENV['CONFIG'] || File.join(File.dirname(__FILE__), '../config.rb')
|
||||
end
|
||||
config = {:url_prefix => ""}
|
||||
config = {
|
||||
:url_prefix => "",
|
||||
:devops_dir => File.join(ENV["HOME"], ".devops")
|
||||
}
|
||||
if File.exists? config_file
|
||||
eval File.read config_file
|
||||
else
|
||||
raise "No config file '#{config_file}' found"
|
||||
end
|
||||
config[:devops_dir] = File.join(ENV["HOME"], ".devops") if config[:devops_dir].nil?
|
||||
addr = first_public_ipv4 || first_private_ipv4
|
||||
config[:address] = if addr.nil?
|
||||
"localhost"
|
||||
|
||||
Loading…
Reference in New Issue
Block a user