diff options
| author | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2014-01-13 12:33:04 -0800 |
|---|---|---|
| committer | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2014-01-13 12:33:04 -0800 |
| commit | 8b70319c270415e9f99ed8eb1f12dd1caaade1fd (patch) | |
| tree | 8c9ed3620235437aa4fd2cc23e9d0a9f9774a9d7 | |
| parent | fe24a383d100afcd6c8a1f8a121ddd9fe53a2e9a (diff) | |
| parent | b9095ec95c38e17425eef26018aeb962e96c323f (diff) | |
| download | rails-8b70319c270415e9f99ed8eb1f12dd1caaade1fd.tar.gz rails-8b70319c270415e9f99ed8eb1f12dd1caaade1fd.tar.bz2 rails-8b70319c270415e9f99ed8eb1f12dd1caaade1fd.zip | |
Merge pull request #13703 from schneems/schneems/rail-secrets-key
Favor canonical environment variables for secrets
| -rw-r--r-- | railties/lib/rails/generators/rails/app/templates/config/secrets.yml | 2 | ||||
| -rw-r--r-- | railties/test/isolation/abstract_unit.rb | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/railties/lib/rails/generators/rails/app/templates/config/secrets.yml b/railties/lib/rails/generators/rails/app/templates/config/secrets.yml index 6e2c45e119..b2669a0f79 100644 --- a/railties/lib/rails/generators/rails/app/templates/config/secrets.yml +++ b/railties/lib/rails/generators/rails/app/templates/config/secrets.yml @@ -19,4 +19,4 @@ test: # Do not keep production secrets in the repository, # instead read values from the environment. production: - secret_key_base: <%%= ENV["RAILS_SECRET_KEY_BASE"] %> + secret_key_base: <%%= ENV["SECRET_KEY_BASE"] %> diff --git a/railties/test/isolation/abstract_unit.rb b/railties/test/isolation/abstract_unit.rb index a1f1973563..6c50911666 100644 --- a/railties/test/isolation/abstract_unit.rb +++ b/railties/test/isolation/abstract_unit.rb @@ -93,8 +93,8 @@ module TestHelpers # Build an application by invoking the generator and going through the whole stack. def build_app(options = {}) @prev_rails_env = ENV['RAILS_ENV'] - ENV['RAILS_ENV'] = 'development' - ENV['RAILS_SECRET_KEY_BASE'] ||= SecureRandom.hex(16) + ENV['RAILS_ENV'] = "development" + ENV['SECRET_KEY_BASE'] ||= SecureRandom.hex(16) FileUtils.rm_rf(app_path) FileUtils.cp_r(app_template_path, app_path) |
