I am running the following setup:
[public ip]-nginx_proxy-[lan]-apache_server
SSL is configured and set up on the nginx proxy level (and this is working).
However, when I visit a site over ssl, I get .css and .js files returned over http (which are blocked by the browser). It seems like Apache is unaware that the client is requesting content over ssl.
This is my current config:
nginx:
server { listen 443; server_name maiev.domain.com, ~.; ssl on; ssl_certificate /etc/nginx/ssl/domain.pem; ssl_certificate_key /etc/nginx/ssl/domain.pem; access_log off; error_log off; location ~ /\.ht { deny all; } location ~ /\.git { deny all; } location / { proxy_pass http://maiev.local:80; proxy_set_header Host $host; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header X-Forwarded-Proto $scheme; add_header Front-End-Https on; proxy_redirect off; } } This is my Apache config:
<VirtualHost *:80> ServerAdmin [email protected] ServerName dev.domain.com <IfModule rpaf_module> RPAFenable On RPAFsethostname On RPAFproxy_ips 172.16.1.130 RPAFheader X-Forwarded-For </IfModule> DocumentRoot /home/sites/www/dev-domain/public <Directory /> Options FollowSymLinks AllowOverride None </Directory> <Directory /home/sites/www/dev-domain/public/> Options Indexes FollowSymLinks MultiViews AllowOverride None Order allow,deny allow from all </Directory> ErrorLog /home/sites/logs/dev-domain/error.log LogLevel warn CustomLog /home/sites/logs/dev-domain/access.log combined php_value log_errors on php_value error_log /home/sites/logs/dev-domain/php.log </VirtualHost> If I change the $scheme to https in the nginx config, nothing changes.
What am I missing?
X-Forwarded-Protoheader?.cssand.jsusing absolute URL's (using plain HTTP) instead of relative ones?