Nginx, wordpress: Unable to proper reverse proxy caching due to Set-Cookie. Recommendation for a good strategy

view full story

http://serverfault.com – I am trying to do reverse proxy caching for a wordpress blog and I am hit with snags. The initial configuration was a simple reverse caching like this location / { proxy_cache_key "$scheme://$host$request_uri"; proxy_cache staticfilecache; proxy_pass http://wordpressapache; add_header Cache-Control public; proxy_cache_valid 200 302 10d; I quickly realized that logged in users will be sent for a toss with and so I did proxy_set_header X-Real-IP $remote_addr; proxy_set_header Host $host; proxy_set_header X-Forwarded-For $proxy_add_x_forward (HowTos)