Looking to get the host string from something other than 'global $base_url'.
Use case: Our implementation currently runs two Drupal servers (drupal1.domain.com & drupal2.domain.com) behind a load balancer (lb.domain.com). Anonymous users (public webpages) are served through the load balancer and therefore has the URL lb.domain.com. This is the host string that needs to be used for Varnish commands.
Authenticated users need to go either directly to one of the two Drupal servers. But if $base_url is set to the load balancer, then authenticated users get redirected to go through load balancer which is not what we want. So we do NOT set the $base_url. As such, Varnish module is currently, by default, issuing commands to drupal1.domain.com or drupal2.domain.com instead of lb.domain.com
Comment | File | Size | Author |
---|---|---|---|
#1 | configurable-host-string-1231480-1.patch | 1.62 KB | nmc |
Comments
Comment #1
nmc CreditAttribution: nmc commentedHere's my first attempt at a providing a configurable host string through the Varnish configurations form...
Comment #2
nmc CreditAttribution: nmc commentedComment #3
pamatt CreditAttribution: pamatt commentedI see it's old, but I applied the patch and it works fine.
Comment #4
MiSc CreditAttribution: MiSc commentedPatch need an re-roll.