Add a default random for secrets

Add a default random for APP_SECRET_KEY_BASE to avoid startup issues.
This commit is contained in:
Ari Timonen 2020-04-11 16:01:56 +03:00
parent 3e22b06f30
commit f8d6368f10

View file

@ -1,11 +1,11 @@
development:
secret_key_base: <%= ENV["APP_SECRET_KEY_BASE"] %>
secret_key_base: <%= ENV["APP_SECRET_KEY_BASE"] || SecureRandom.alphanumeric(32) %>
test:
secret_key_base: <%= ENV["APP_SECRET_KEY_BASE"] %>
secret_key_base: <%= ENV["APP_SECRET_KEY_BASE"] || SecureRandom.alphanumeric(32) %>
production:
secret_key_base: <%= ENV["APP_SECRET_KEY_BASE"] %>
secret_key_base: <%= ENV["APP_SECRET_KEY_BASE"] || SecureRandom.alphanumeric(32) %>
staging:
secret_key_base: <%= ENV["APP_SECRET_KEY_BASE"] %>
secret_key_base: <%= ENV["APP_SECRET_KEY_BASE"] || SecureRandom.alphanumeric(32) %>