In debian jessie I'm trying to serve https with a varnish reverse proxy, and I found the following solution: http://davidbu.ch/mann/blog/2015-03-20/varnish-and-https-apache.html : apache manages ssl stuff on port 443, then passes to varnish on port 80, which passes to apache at port 8080.
However, requesting https://myserver.com/index.html
I get in the browser:
403 Forbidden
You don't have permission to access / on this server.
Apache's error.log says:
[authz_core:error] [pid 12662] [client 151.16.175.15:38240] AH01630: client denied by server configuration: proxy:http://127.0.0.1:80/index.html
What am I missing?
My vhost definition
<VirtualHost *:8080>
ServerAdmin mymail@gmail.com
ServerName myserver.com
DocumentRoot /home/paolo/weewx
<Directory /home/paolo/weewx/>
DirectoryIndex index.html
Options FollowSymLinks
AllowOverride All
Require all granted
order allow,deny
allow from all
</Directory>
ErrorLog /var/log/apache2/error.log
# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
LogLevel warn
# ErrorDocument 404 /index.html
CustomLog /var/log/apache2/access.log combined
</VirtualHost>
<IfModule mod_ssl.c>
<VirtualHost *:443>
ServerAdmin mymail@gmail.com
ServerName myserver.com
DocumentRoot /home/paolo/weewx/
<Directory /home/paolo/weewx/>
DirectoryIndex index.html
Options FollowSymLinks
AllowOverride All
order allow,deny
allow from all
</Directory>
ErrorLog /var/log/apache2/error.log
# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
LogLevel warn
# ErrorDocument 404 /index.html
CustomLog /var/log/apache2/access.log combined
ProxyPreserveHost On
ProxyPass / http://127.0.0.1:80/
ProxyPassReverse / http://127.0.0.1:80/
RequestHeader set X-Forwarded-Port "443"
RequestHeader set X-Forwarded-Proto "https"
Include /etc/letsencrypt/options-ssl-apache.conf
SSLCertificateFile /etc/letsencrypt/live/qumran2/fullchain.pem
SSLCertificateKeyFile /etc/letsencrypt/live/qumran2/privkey.pem
</VirtualHost>
</IfModule>