I have a rails app. I just ran a migration that copied data from one column over to another. I tested extensively in development.
But now that I’ve run this on production my data got corrupted. Notably, this column is using the ActiveRecord encryption which requires that the ENV be set in order for the proper secret key to be used.
I’m really stumped as to why the data seems to be encrypted with a DIFFERENT key than is in my ENV (and I’m trying to figure out what this key is so I can decrypt this data…).
Is it definitely the case that Fly secrets get set as ENV when the release_command runs? I’ve not figured out an easy way to verify this.
If anyone from Fly can peek at my logs for my app “the-bot”, the string to search for is “Configuring active record encryption from environment”. This is outputted in my rails initialization process based on the presence of certain ENV keys.
I’ve not yet been able to find how I search logs from a few hours ago. I’m still looking…