Skip to content

Instantly share code, notes, and snippets.

@hungryzi
Created August 25, 2013 09:52
Show Gist options
  • Save hungryzi/6333049 to your computer and use it in GitHub Desktop.
Save hungryzi/6333049 to your computer and use it in GitHub Desktop.
Load secret_token from ENV
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