0
0
Fork 0

Enable AR Encryption (#29831)

This commit is contained in:
Matt Jankowski 2024-04-17 05:19:02 -04:00 committed by GitHub
parent a390299744
commit 828299e71c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
7 changed files with 53 additions and 2 deletions

View file

@ -36,6 +36,15 @@ namespace :mastodon do
env[key] = SecureRandom.hex(64)
end
# Required by ActiveRecord encryption feature
%w(
ACTIVE_RECORD_ENCRYPTION_DETERMINISTIC_KEY
ACTIVE_RECORD_ENCRYPTION_KEY_DERIVATION_SALT
ACTIVE_RECORD_ENCRYPTION_PRIMARY_KEY
).each do |key|
env[key] = SecureRandom.alphanumeric(32)
end
vapid_key = Webpush.generate_key
env['VAPID_PRIVATE_KEY'] = vapid_key.private_key