Devise Secret Key was not set

前端 未结 16 1237
别那么骄傲
别那么骄傲 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:11

    I do not know right solution but it's working. You can try it. I was cloned my project from my GitLab account and when I run in my local server, I have an error Message:

    rake aborted! Devise.secret_key was not set. Please add the following to your Devise initializer: config.secret_key = '-- secret key --'

    Open config/initializers/devise.rb and add this line

    config.secret_key = '<%= ENV["SECRET_KEY_BASE"] %>'

    This code line is solved my problem.

提交回复
热议问题