crabgrass/config/secrets.yml

17 lines
630 B
YAML

<% #If its around we still use the old secret file %>
<% #to migrate sessions from previous version %>
<% old_secret = File.read(CRABGRASS_SECRET_FILE).chomp rescue nil %>
development:
secret_key_base: 8a10650ac87e29d30fd6951ec00fb5e36670923a529980a3cea3b50d70af379a3cfd3eb35b1117d6f6558645aaea1e8ceab34f2a35ed9ff878b48e8e9d3d5264
secret_token: <%= old_secret %>
test:
secret_key_base: <%= SecureRandom.hex(64) %>
#FIXME: remove the fallback once we have ENV["SECRET_KEY_BASE"] set in
# staging.
production:
secret_key_base: <%= ENV["SECRET_KEY_BASE"] || SecureRandom.hex(64) %>
secret_token: <%= old_secret %>