Missing encryption key to decrypt file with: Rails Development environment

Viewed 2274

I've been working on a rails app & I'm sharing the code with someone through github. When I run the code locally on my machine, everything works fine, but when they run the code on their local environment they get this error:

Missing encryption key to decrypt file with. Ask your team for your master key and write it to /Users/krys2fa/articles/config/master.key or put it in the ENV['RAILS_MASTER_KEY'].

Does anyone know how I can fix this?? Thank you :)

1 Answers

Tell your buddy to run:

EDITOR="nano" rails credentials:edit

This command will open the nano editor and will let create your credentials file. Once then tell him to restart his server.

Remember to not to include this file in the version system. By default it is ignored in the .git file, so it is very likely your partner does not have it.

It is very weird that you can run it but your partner doesn't. Are you sure he is not requiring the master key file in development.rb ?

Related