Mailing List Archive

Varnish URL rewrite
Hi guys!

I'm tried to rewrite an url with varnish, and i need the help of yours:

The URL www.meysite.com/something redirect to subpage "Something"

but

the url mysite.com/something redirect to home :S

How can i save all after "/" and rewrite the url with "www"
Ex.

request url = mysite.com/something
after rewrite = www.mysite.com/something

Thanks!

rabeloo
Re: Varnish URL rewrite [ In reply to ]
Hi,

I think what you want is described in the wiki (see the req.http.host
example):

https://www.varnish-cache.org/trac/wiki/RedirectsAndRewrites

If you want to send a redirect to the browser try something like this:

https://www.varnish-cache.org/trac/wiki/VCLExampleRedirectInVCL


2013/3/22 Raphael Rabelo <rabelo@raphaelr.com.br>

> Hi guys!
>
> I'm tried to rewrite an url with varnish, and i need the help of yours:
>
> The URL www.meysite.com/something redirect to subpage "Something"
>
> but
>
> the url mysite.com/something redirect to home :S
>
> How can i save all after "/" and rewrite the url with "www"
> Ex.
>
> request url = mysite.com/something
> after rewrite = www.mysite.com/something
>
> Thanks!
>
> rabeloo
>
> _______________________________________________
> varnish-misc mailing list
> varnish-misc@varnish-cache.org
> https://www.varnish-cache.org/lists/mailman/listinfo/varnish-misc
>



--
Paulo Silva <paulojjs@gmail.com>