mirror of
https://github.com/System-End/identity-vault.git
synced 2026-04-19 22:05:07 +00:00
why did this ever work
This commit is contained in:
parent
c832901a51
commit
47ec49f62f
1 changed files with 3 additions and 0 deletions
|
|
@ -6,6 +6,9 @@ elsif Rails.env.development? || Rails.env.test?
|
|||
# generate a deterministic key for dev/test so encrypted data persists across restarts
|
||||
# this is NOT secure for production – always set LOCKBOX_MASTER_KEY in prod
|
||||
Lockbox.master_key = Digest::SHA256.hexdigest("hca-dev-key")
|
||||
elsif ENV["SECRET_KEY_BASE_DUMMY"].present?
|
||||
# allow Rails to boot during asset precompilation without real secrets
|
||||
Lockbox.master_key = "0" * 64
|
||||
else
|
||||
raise "LOCKBOX_MASTER_KEY must be set in production"
|
||||
end
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue