Skip to content

Instantly share code, notes, and snippets.

@keokilee keokilee/https.conf Secret
Created Mar 25, 2015

What would you like to do?
Rails On Windows - HTTPS Config
<VirtualHost _default_:80>
ServerName localhost
Redirect permanent / https://localhost
# Default SSL Virtual Host configuration.
<IfModule !ssl_module>
LoadModule ssl_module modules/
Listen 443
<VirtualHost _default_:443>
ServerName localhost
DocumentRoot “C:/<ruby stack>/projects/<project dir>/public”
<Directory “C:/<ruby stack>/projects/<project dir>/public”>
Allow from all
Options -MultiViews
Require all granted
RewriteEngine On
SSLProxyEngine On
SSLEngine On
SSLProxyVerify none
SSLProxyCheckPeerCN off
SSLProxyCheckPeerName off
SSLProxyCheckPeerExpire off
SSLCertificateFile “C:/<path to ssl cert>/cert.pem”
SSLCertificateKeyFile “C:/<path to ssl cert>/server.key”
SSLProxyMachineCertificateFile “C:/<path to ssl cert>/key.pem”
RewriteRule ^/(.*)$ balancer://app_balancers%{REQUEST_URI} [P,QSA,L]
<Proxy balancer://app_balancers>
BalancerMember https://localhost:3000/
BalancerMember https://localhost:3001/
<LocationMatch “^/assets/.*$”>
Header unset ETag
FileETag None
# RFC says only cache for 1 year
ExpiresActive On
ExpiresDefault “access plus 1 year”
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.