Mapping a domain to URI of drupal

Jerais Al-Jeraisy jerais at kernel.com.sa
Tue Jul 27 13:17:56 CEST 2010


Thank you for reply.
still the same issue.

one thing, is there any difference of the place of the rule?
because if i placed it directly after the declaration "sub vcl_recv {" it
opens for me BUT after long loading and it doesn't open all the content of
the page, without the CSS and images for example.
and if i placed it just before the " return (lookup); }", the end of sub
vcl_recv, it opens for once and next time it opens the default page without
the URI, the same issue as before.

appropriated your help.

//JJ



On Tue, Jul 27, 2010 at 13:53, Flavio Torres <fla_torres at yahoo.com.br>wrote:

> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Em 27/7/2010 06:54, Jerais Al-Jeraisy escreveu:
> > We have varnish-2.0.6 on CentOS 5.5 in front of Apache & drupal, and
> > we tried to map the domain ww.xx.yy.zz to a drupal URI, like
> > /websites/a/b/c, so any one can hit ww.xx.yy.zz directly insted of
> > wiritng ww.xx.yy.zz/websites/a/b/c.
> > it works fine for the first time, but the next time i hit the same
> > URL, it directs me to the main page of drupal, not to the URI, and i
> > should delete all my temp files to get it to work again.
>
> Jerais,
>
> I think rewrite should be useful, try this:
>
> if (req.http.host ~ "^(www\.)?your\.domain\.com$") {
>  set req.url = regsub(req.url, "^", "/websites/a/b/c");
> }
>
>
> regards,
>
>
>
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.8 (MingW32)
>
> iEYEARECAAYFAkxOusYACgkQNRQApncg295jDwCghEoqNx5OK4wjt4g8axxini++
> JGYAoMgax11t56NJFHY/frolqg97ZQUr
> =OwwC
> -----END PGP SIGNATURE-----
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.varnish-cache.org/lists/pipermail/varnish-misc/attachments/20100727/685a2f7a/attachment-0003.html>


More information about the varnish-misc mailing list