title: Glassfish HTTPS redirect behind SSL offloader and Apache
body: <p>I have this configuration:</p>
  
  <ul>
  <li>HTTPS load balancer / SSL offloader on port 443 </li>
  <li>Apache httpd on port 80 (different IP), using ProxyPass, ProxyPassReverse to forward to...</li>
  <li>multiple Glassfish domains listening on different ports</li>
  </ul>
  
  <p>Problem: Neither Glassfish nor Apache is aware that the request is HTTPS.  Redirects to URLs like "/index.jsp" are being rewritten in Glassfish as <code>http://internal_ip/index.jsp</code>, then ProxyPassReverse rewrites to <code>http://public_ip/index.jsp</code>.  Problem is, I need that URL to be <code>http*s*://public_ip/...</code></p>
  
  <p>How do I fix that - is there some Glassfish configuration I can change, or Apache httpd.conf?  </p>