Take the 2-minute tour ×

I'm using Heroku and Rails 3.1 with an SSL certificate for secure.example.com.

I only want pages with forms (secure.example.com/login, for example) to be behind secure.example.com. Any ideas?

share|improve this question

1 Answer 1

There's always the classic: https://github.com/rails/ssl_requirement. You can also introduce some middleware for all requests or roll your own before filter as described here: Force SSL using ssl_requirement in Rails app

share|improve this answer

Your Answer


