Dennis Hackethal’s Blog
My blog about philosophy, coding, and anything else that interests me.
Success! You can now read the full article below. Be sure to save it to PDF before leaving or refreshing the page!
Need help? Email me and be sure to include this reference number:
Using Rails Production Credentials with Heroku
Ruby on Rails offers a credentials feature to store secret information in your repository. The keys Rails creates are added to the
.gitignore file, but any secret information itself is encrypted and can be checked into git. There’s more info on credentials here.
I found myself confronted with the specific problem of how to use these credentials in Heroku. If you’re using only a master key and store your credentials in
config/credentials.ymc.enc, that’s easy: you just set an environment variable in Heroku called
RAILS_MASTER_KEY to the contents of your
But wait, there’s more!
You’re reading a preview of this. Pro articles are written with exceptional care and provide additional value. Purchase the full article for only USD 0.99.
Is this secure?
Yes. Your credit-card details are handled securely and in a PCI-compliant manner using the trusted payment processor Stripe.
What about privacy?
What if something goes wrong?
If, say, due to technical issues, or for whatever other reason, you cannot see the full article after purchasing it, simply email me and I’ll send you a copy. Please include your reference number starting with ‘pi_…’, if you have it. That reference number is shown to you right after you make the purchase.
Can I get a refund?
Yes. If you purchased an article and didn’t like it, email me and you’ll get a full refund, no questions asked. I will need the reference number starting with ‘pi_…’ to process the refund. That reference number is shown to you right after you make the purchase. Write it down carefully – I am unable to issue refunds without this reference number.
Can I share the full article with others?
The full article is copyrighted and only for your own, personal use. As such, you may not share it with others beyond what’s previewed before purchasing it. However, you are more than welcome to share a link to this page so others can purchase the article, too.