# Apache httpd front for the SLeeLa HTTP 3.0 module. # # Terminates HTTP/2 (and HTTP/1.1) from the internet and reverse-proxies to the # Tomcat h2c connector on :8080, so standard clients reach the SleelaH3Servlet # over HTTP/2+ while the H3 envelope rides untouched in the request body. # # Enable the required modules first: # a2enmod http2 proxy proxy_http proxy_http2 ssl headers # then place this file in conf-available/ (Debian/Ubuntu) or conf.d/ (RHEL) # and reload: apachectl -k graceful # Advertise HTTP/2 (h2 over TLS, h2c cleartext) on this server. Protocols h2 h2c http/1.1 ServerName sleela.localhost SSLEngine on SSLCertificateFile /etc/ssl/certs/sleela.crt SSLCertificateKeyFile /etc/ssl/private/sleela.key # Keep the H3 body byte-exact: do not let the proxy transform request bodies. SetEnv proxy-sendcl 1 RequestHeader set X-Forwarded-Proto "https" # Reverse-proxy to Tomcat's h2c connector. proxy_http2 preserves HTTP/2 # semantics to the backend; the H3 envelope in the body is opaque to Apache. ProxyPreserveHost On ProxyPass /sleela/ h2c://127.0.0.1:8080/sleela/ ProxyPassReverse /sleela/ h2c://127.0.0.1:8080/sleela/ # Cleartext virtual host (h2c + http/1.1) for local testing without TLS. ServerName sleela.localhost ProxyPreserveHost On ProxyPass /sleela/ h2c://127.0.0.1:8080/sleela/ ProxyPassReverse /sleela/ h2c://127.0.0.1:8080/sleela/