Created
January 31, 2011 15:33
-
-
Save jxpx777/804195 to your computer and use it in GitHub Desktop.
Initializer file that loads a YML file for config information for the current environment.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
production: | |
site_url: http://mywebsite.com | |
ssl_site_url: https://mywebsite.com | |
licenses_folder: /path/to/shared/licenses | |
ferret_index_path: /path/to/shared/ferret/index | |
test: | |
development: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# encoding: UTF-8 | |
agile_config_file = Rails.root.join('config', 'ag_constants.yml') | |
raise "#{agile_config_file} is missing!" unless File.exists?(agile_config_file) | |
agile_config = YAML.load_file(agile_config_file)[Rails.env].symbolize_keys rescue {} | |
SITE_URL = agile_config[:site_url] | |
SSL_SITE_URL = agile_config[:ssl_site_url] | |
LICENSES_FOLDER = agile_config[:licenses_folder] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment