title: What's the correct way of defining secret_key_base on Rails 6?
body: <p>What's the correct way of defining <code>secret_key_base</code> on Rails 6 now that we have per-environment credentials?</p>
  
  <p>My environment has the variable <code>SECRET_KEY_BASE</code> but Rails is not picking it up. I tried defining <code>secret_key_base</code> in <code>config\credentials\production.yml.enc</code> but it has no effect on <code>Rails.application.credentials.secret_key_base</code></p>
  
  <p>I know <code>config/secrets.yml</code> with</p>
  
  <pre><code>staging:
    secret_key_base: &lt;%= ENV["SECRET_KEY_BASE"] %&gt;
  
  production:
    secret_key_base: &lt;%= ENV["SECRET_KEY_BASE"] %&gt;
  </code></pre>
  
  <p>works, but, is that the Rails 6 way?</p>