Drop Rails.application.secrets usage

That feature is gone and we already use environment variables...

https://github.com/rails/rails/pull/47801
This commit is contained in:
Henne Vogelsang 2025-08-12 14:37:45 +02:00
parent 4ec9aee5da
commit ddcd8dfc69
No known key found for this signature in database
GPG key ID: 97DDB66BDAF8D4D6
7 changed files with 9 additions and 89 deletions

View file

@ -7,11 +7,9 @@ Devise.setup do |config|
# Pass each provider to User model in :omniauth_providers (for open_id providers use their name)
config.omniauth :open_id, name: 'suse', identifier: 'http://www.opensuse.org/openid/user'
config.omniauth :google_oauth2, ENV.fetch('OSEM_GOOGLE_KEY', Rails.application.secrets.google_key), ENV.fetch('OSEM_GOOGLE_SECRET', Rails.application.secrets.google_secret),
name: 'google',
scope: 'email'
config.omniauth :facebook, ENV.fetch('OSEM_FACEBOOK_KEY', Rails.application.secrets.facebook_key), ENV.fetch('OSEM_FACEBOOK_SECRET', Rails.application.secrets.facebook_secret)
config.omniauth :github, ENV.fetch('OSEM_GITHUB_KEY', Rails.application.secrets.github_key), ENV.fetch('OSEM_GITHUB_SECRET', Rails.application.secrets.github_secret)
config.omniauth :google_oauth2, ENV.fetch('OSEM_GOOGLE_KEY', nil), ENV.fetch('OSEM_GOOGLE_SECRET', nil), name: 'google', scope: 'email'
config.omniauth :facebook, ENV.fetch('OSEM_FACEBOOK_KEY', nil), ENV.fetch('OSEM_FACEBOOK_SECRET', nil)
config.omniauth :github, ENV.fetch('OSEM_GITHUB_KEY', nil), ENV.fetch('OSEM_GITHUB_SECRET', nil)
# ==> Mailer Configuration
# Configure the e-mail address which will be shown in Devise::Mailer,