Devise Secret Key was not set

前端 未结 16 1263
别那么骄傲
别那么骄傲 2020-11-27 14:53

I am developing a Rails 4 app using the Active Admin gem for the administration back end. Active Admin in turn uses Devise for user authentication. Now, when I try to deploy

16条回答
  •  情话喂你
    2020-11-27 15:10

    In config/initializers/devise.rb I put:

    config.secret_key = ENV["SECRET_KEY_BASE"] if Rails.env.production?
    

    Because if you put:

    $ heroku config
    

    You'll see a secret_key_base for the mode production.

提交回复
热议问题