Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/diaspora/diaspora.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMaxwell Salzberg <maxwell@joindiaspora.com>2012-01-19 03:09:08 +0400
committerMaxwell Salzberg <maxwell@joindiaspora.com>2012-01-19 03:09:08 +0400
commit18e895c2475c65148c4086361e49e6a07428d7f7 (patch)
treed892c70dab89bc1d53ef750fa48d7420e592b582 /config/environments
parentff615848ca7912423c6a44e9146c274d89c0394f (diff)
include Rack::SSL to upgrade all requests to ssl
Diffstat (limited to 'config/environments')
-rw-r--r--config/environments/production.rb3
1 files changed, 3 insertions, 0 deletions
diff --git a/config/environments/production.rb b/config/environments/production.rb
index e0a9f8f1b..ac0a93e82 100644
--- a/config/environments/production.rb
+++ b/config/environments/production.rb
@@ -37,6 +37,9 @@ Diaspora::Application.configure do
# In production, Apache or nginx will already do this
config.serve_static_assets = false
+ #force ssl in production
+ config.middleware.insert_before ActionDispatch::Static, "Rack::SSL"
+
# Enable serving of images, stylesheets, and javascripts from an asset server
# config.action_controller.asset_host = "http://assets.example.com"