mirror of
https://github.com/ENSL/ensl.org.git
synced 2025-01-27 03:30:54 +00:00
Attempt to use rails 3 sessions
This commit is contained in:
parent
38b58cb4a9
commit
b9c5fe7565
2 changed files with 6 additions and 5 deletions
|
@ -41,8 +41,9 @@ module Ensl
|
|||
config.autoload_paths += Dir["#{config.root}/app/services/**/", "#{config.root}/app/models/concerns/"]
|
||||
|
||||
# Be sure to restart your server when you modify this file.
|
||||
config.session_store :cookie_store, key: '_ENSL_session_key'
|
||||
config.session_store :cookie_store, key: '_ENSL_session_key', domain: ENV[ENV['RAILS_ENV'].upcase + "_DOMAIN"]
|
||||
# config.session_store :my_custom_store, key: '_ENSL_session_key'
|
||||
config.action_dispatch.cookies_serializer = :marshal
|
||||
|
||||
# Load secrets from .env
|
||||
ENV['APP_SECRET'] ||= (0...32).map { (65 + rand(26)).chr }.join
|
||||
|
|
|
@ -1,11 +1,11 @@
|
|||
development:
|
||||
secret_key_base: <%= ENV["APP_SECRET_KEY_BASE"] %>
|
||||
secret_token: <%= ENV["APP_SECRET"] %>
|
||||
|
||||
test:
|
||||
secret_key_base: <%= ENV["APP_SECRET_KEY_BASE"] %>
|
||||
secret_token: <%= ENV["APP_SECRET"] %>
|
||||
|
||||
production:
|
||||
secret_key_base: <%= ENV["APP_SECRET_KEY_BASE"] %>
|
||||
secret_token: <%= ENV["APP_SECRET"] %>
|
||||
|
||||
staging:
|
||||
secret_key_base: <%= ENV["APP_SECRET_KEY_BASE"] %>
|
||||
secret_token: <%= ENV["APP_SECRET"] %>
|
||||
|
|
Loading…
Reference in a new issue