Sha256: d09a35bc5d2a9b61fcf0c51c90db2ad2c08ddc5ab238f85869584595955d8142
Contents?: true
Size: 1008 Bytes
Versions: 9
Compression:
Stored size: 1008 Bytes
Contents
= New Features * A redirect_http_to_https plugin has been added, redirecting HTTP requests to the same path on an HTTPS site. Using the routing tree, you can control where to do the redirection, which allows you to easily have part of your site accessible via HTTP, with sensitive sections requiring HTTPS: plugin :redirect_http_to_https route do |r| # routes available via both HTTP and HTTPS r.redirect_http_to_https # routes available only via HTTPS end If you want to redirect to HTTPS for all routes in the routing tree, you can have r.redirect_http_to_https as the very first method call in the routing tree. Note that in Roda it is possible to handle routing before the normal routing tree using before hooks. The static_routing and heartbeat plugins use this feature. If you would like to handle routes before the normal routing tree, you can setup a before hook: plugin :hooks before do request.redirect_http_to_https end
Version data entries
9 entries across 9 versions & 1 rubygems