Last active
October 7, 2015 00:07
-
-
Save codingfoo/3073836 to your computer and use it in GitHub Desktop.
Load a secrets file
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
require 'ostruct' | |
require 'yaml' | |
::Secrets = OpenStruct.new(YAML.load_file(File.expand_path('../secrets.yml', __FILE__))[Rails.env]) |
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
default: &DEFAULT | |
# Default Configuration | |
production: | |
<<: *DEFAULT | |
# Add production specific secrets | |
staging: | |
<<: *DEFAULT | |
# Add staging specific secrets | |
development: | |
<<: *DEFAULT | |
# Development specific secrets | |
test: | |
<<: *DEFAULT | |
# Test specific secrets |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment