0

My configuration is: Internet -> Nginx as SSL-Offloader -> Varnish -> Nginx + PHP

When I send a redirect from PHP to https://foo.bar I see http://foo.bar. It looks like Varnish rewrites Location header in response. How can I fix it?

It's Ok in configuration without Varnish: Internet -> Nginx as SSL-Offloader -> Nginx + PHP

2 Answers2

1

Solved :) The problem was in balancer (Pound) config. Internet -> Pound -> Nginx as SSL-Offloader -> Varnish -> Nginx + PHP

I set RewriteLocation to 0 and it solve the issue.

-1

Varnish does not support ssl. There is official explanation why: https://www.varnish-cache.org/docs/trunk/phk/ssl.html

Mantas
  • 4,259
  • 2
  • 27
  • 32