Configure OSEM via environment variables

Instead of reading a yaml file we get configuration from the
environment.
This commit is contained in:
Henne Vogelsang 2016-03-22 18:14:40 +01:00
parent 45c31f210f
commit ebcb2780cd
17 changed files with 39 additions and 34 deletions

View file

@ -13,7 +13,7 @@ class ConferenceRegistrationsController < ApplicationController
redirect_to edit_conference_conference_registrations_path(@conference.short_title)
return
# ichain does not allow us to create users during registration
elsif CONFIG['authentication']['ichain']['enabled'] && !current_user
elsif (ENV['OSEM_ICHAIN_ENABLED'] == 'true') && !current_user
redirect_to root_path, alert: 'You need to sign in or sign up before continuing.'
return
end