Created
August 25, 2013 09:52
-
-
Save hungryzi/6333049 to your computer and use it in GitHub Desktop.
Load secret_token from 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
secret = ENV['SECRET_TOKEN'] | |
if secret.length < 30 | |
raise "Secret token cannot be loaded" | |
else | |
Rails.application.config.secret_token = secret | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment