> On Apr 3, 2015, at 4:56 AM, Nick Kew <[email protected]> wrote: > > On Fri, 2015-04-03 at 10:44 +0200, tomr wrote: >> Hi, >> >> I’m struggling to figure out if it’s possible to do something like this: >> >> map http://domain.com/ http://origin.domain.com @action=allow @method=get >> @method=head >> map http://domain.com/ http://post-origin.domain.com @action=allow >> @method=post >> >> Any clues? > > The regexp_remap plugin gives you the option to match method > in mapping rules. > > https://docs.trafficserver.apache.org/en/latest/reference/plugins/regex_remap.en.html
Yes, you can deal with this via a plugin (like the above and Lua). Just to clarify for Tom: The @action stuff are ACLs, it says “Only allow requests for method=GET”. You can’t use these for map rule selection criteria. I’m surprised that the above configuration doesn’t give errors actually, it ought to complain that there’s a duplication (it should say something about not being able to put it into the trie). — leif
