lib/rest-ftp-daemon/settings.rb in rest-ftp-daemon-0.214.0 vs lib/rest-ftp-daemon/settings.rb in rest-ftp-daemon-0.220.0
- old
+ new
@@ -23,11 +23,11 @@
def init_defaults
Settings['host'] ||= `hostname`.chomp.split('.').first
end
def newrelic_enabled?
- Settings.newrelic.is_a?(Hash) && Settings.at(:newrelic, :license)
+ Settings.at(:debug, :newrelic)
end
def init_newrelic
# Skip if not enabled
return ENV['NEWRELIC_AGENT_ENABLED'] = 'false' unless Settings.newrelic_enabled?
@@ -36,13 +36,13 @@
ENV['NEWRELIC_AGENT_ENABLED'] = 'true'
ENV['NEW_RELIC_MONITOR_MODE'] = 'true'
#Settings['newrelic']['enabled'] = true
# License
- ENV['NEW_RELIC_LICENSE_KEY'] = Settings.at(:newrelic, :license)
+ ENV['NEW_RELIC_LICENSE_KEY'] = Settings.at(:debug, :newrelic)
# Appname
- ENV['NEW_RELIC_APP_NAME'] = Settings.at(:newrelic, :appname) || "#{APP_NICK}-#{Settings.host}-#{APP_ENV}"
+ ENV['NEW_RELIC_APP_NAME'] = "#{APP_NICK}-#{Settings.host}-#{APP_ENV}"
# Logfile
ENV['NEW_RELIC_LOG'] = Settings.at(:logs, :newrelic)
end