From 326b157456b2432cc340b07a74ea04eca420a00a Mon Sep 17 00:00:00 2001 From: mo khan Date: Sat, 17 Aug 2019 13:34:55 -0600 Subject: force_ssl in production --- app/controllers/metadata_controller.rb | 5 ----- config/environments/production.rb | 2 +- 2 files changed, 1 insertion(+), 6 deletions(-) diff --git a/app/controllers/metadata_controller.rb b/app/controllers/metadata_controller.rb index cf3a09e..05dd69c 100644 --- a/app/controllers/metadata_controller.rb +++ b/app/controllers/metadata_controller.rb @@ -1,7 +1,6 @@ # frozen_string_literal: true class MetadataController < ApplicationController - force_ssl if: :ssl_configured? skip_before_action :authenticate! def show @@ -15,8 +14,4 @@ class MetadataController < ApplicationController Idp.default(request).to_xml end end - - def ssl_configured? - Rails.env.production? - end end diff --git a/config/environments/production.rb b/config/environments/production.rb index 1a367f1..a55bab9 100644 --- a/config/environments/production.rb +++ b/config/environments/production.rb @@ -57,7 +57,7 @@ Rails.application.configure do # Force all access to the app over SSL, use Strict-Transport-Security, # and use secure cookies. - # config.force_ssl = true + config.force_ssl = true # Use the lowest log level to ensure availability of diagnostic information # when problems arise. -- cgit v1.2.3