diff --git a/config/routes.rb b/config/routes.rb index 083b017..fad0d72 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -14,6 +14,7 @@ if Dromedary::Services[:rails_url_host] Rails.application.routes.default_url_options[:host] = Dromedary::Services[:rails_url_host] + Rails.application.routes.default_url_options[:protocol] = Dromedary::Services[:rails_url_protocol] end Rails.application.routes.draw do diff --git a/lib/dromedary/services.rb b/lib/dromedary/services.rb index cad1942..4cd3d89 100644 --- a/lib/dromedary/services.rb +++ b/lib/dromedary/services.rb @@ -21,7 +21,7 @@ module Dromedary # running with the proxy handlers and don't explicitly set the path, it borks. Services.register(:rails_url_host) { ENV["RAILS_URL_HOST"] || nil } - + Services.register(:rails_url_protocol) { ENV["RAILS_URL_PROTOCOL"] || nil } } #### NAMING ####