From 0f0974ffdffcd98665f7e36293813e68e0668bcf Mon Sep 17 00:00:00 2001 From: Luke Shumaker Date: Fri, 25 Apr 2014 11:16:20 -0400 Subject: Use Figaro for configuration --- config/application.example.yml | 3 +++ config/initializers/secret_token.rb | 6 +++++- 2 files changed, 8 insertions(+), 1 deletion(-) create mode 100644 config/application.example.yml (limited to 'config') diff --git a/config/application.example.yml b/config/application.example.yml new file mode 100644 index 0000000..a98b40e --- /dev/null +++ b/config/application.example.yml @@ -0,0 +1,3 @@ +SECRET_TOKEN: 'cc884af613d0dd093f1d6c9153abac1200c5a0db923613245b80c5c3f5e9c9f9ba51712b702f2d494a22ddea8ab40601b38a41eb39eec97b50a7a2e37748b1bc' +RIOT_API_KEY: 'ad539f86-22fd-474d-9279-79a7a296ac38' +RIOT_API_REGION: 'na' diff --git a/config/initializers/secret_token.rb b/config/initializers/secret_token.rb index 604d43d..fbab4b9 100644 --- a/config/initializers/secret_token.rb +++ b/config/initializers/secret_token.rb @@ -9,4 +9,8 @@ # Make sure your secret_key_base is kept private # if you're sharing your code publicly. -Leaguer::Application.config.secret_key_base = 'cc884af613d0dd093f1d6c9153abac1200c5a0db923613245b80c5c3f5e9c9f9ba51712b702f2d494a22ddea8ab40601b38a41eb39eec97b50a7a2e37748b1bc' +Leaguer::Application.config.secret_key_base = if Rails.env.development? or Rails.env.test? + ('x' * 30) # meets minimum requirement of 30 chars long +else + ENV['SECRET_TOKEN'] +end -- cgit v1.2.3-2-g168b