I am trying to set up gitlab.com
continuous integration(CI) for one of my private projects. But rails db:migrate
is failing with the following error:
ActiveSupport::EncryptedFile::MissingKeyError: Missing encryption key to decrypt file with. Ask your team for your master key and write it to /builds/shubh-muhurat/Backend/config/master.key or put it in the ENV['RAILS_MASTER_KEY']
The master key
should not be there in the repository, but if I set RAILS_MASTER_KEY
using .gitlab-ci.yml
I have to commit the master key to the repository.
So is there a better way of putting the master key.
PS: I am using gitlab.com
CI.
Version: Rails 5.2.0.beta2