trafficserver-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jeremy Payne <jp557...@gmail.com>
Subject Re: Regex Remap plugin - follow redirect
Date Fri, 04 Dec 2015 21:27:41 GMT
This is doable with the lua plugin.

On Thu, Dec 3, 2015 at 7:51 AM, Steve Malenfant <smalenfant@gmail.com>
wrote:

> Is there way we can modify the path of a filename requested to an origin?
> In this example, I want to remove the "path" portion and only send the
> "filename" to the origin.
>
>
> Looks like regex_map won't work from documentation (there is no
> regex_remap?) :
>
> "Only the host field can contain a regex; the scheme, port, and other
> fields cannot. For path manipulation via regexes, use the regex_remap
> plugin"
>
>
> Here's what I tried :
>
> regex remap plugin line : ^/this.that.com/t.*/(.*)$ http://origin/$1
>
>
> Original remapped request : http://origin/this.that.com/t1/test.ts
>
> Wanted modified request : http://origin/test.ts
>
>
> Although, this returns a 302 redirect to the client instead of forwarding
> to parent or origin.
>
> Hopefully I described this properly. Thanks,
>
>
> Steve
>

Mime
View raw message