comparison config/default_config.rb @ 355:56382cb104dd

Add support for environment variable-based deployment.
author edogawaconan <me@myconan.net>
date Mon, 04 Aug 2014 17:05:16 +0900
parents 96631607785f
children 68eb23b52864
comparison
equal deleted inserted replaced
354:5ac923264129 355:56382cb104dd
1 CONFIG["standalone"] = true if CONFIG["standalone"].nil? 1 CONFIG["standalone"] = true if CONFIG["standalone"].nil?
2 CONFIG["newrelic"] = false if CONFIG["newrelic"].nil? 2 CONFIG["newrelic"] = false if CONFIG["newrelic"].nil?
3 CONFIG["bundler_groups"] ||= [:default, Rails.env] 3 CONFIG["bundler_groups"] ||= [:default, Rails.env]
4 CONFIG["bundler_groups"] << "standalone" if CONFIG["standalone"] 4 CONFIG["bundler_groups"] << "standalone" if CONFIG["standalone"]
5 CONFIG["bundler_groups"] << "newrelic" if CONFIG["newrelic"] 5 CONFIG["bundler_groups"] << "newrelic" if CONFIG["newrelic"]
6
7 CONFIG["secret_key"] ||= ENV["ZP_SECRET_KEY"] if ENV["ZP_SECRET_KEY"]
8 CONFIG["newrelic"] = (ENV["ZP_NEWRELIC"] == 1) if ENV["ZP_NEWRELIC"]