/ Zope / Apsis / Pound Mailing List / Archive / 2012 / 2012-01 / Matching URL pattern in Service definition

[ << ] [ >> ]

[ Re: [Pound Mailing List] Pound 2.7 / Francisco ... ] [ Problem adding third backend / "Jonathan Van ... ]

Matching URL pattern in Service definition
"Andreas H." <lists(at)hilboll.de>
2012-01-01 18:28:18 [ FULL ]
Hi,

this is probably a very noob question, but I cannot seem to get it right:

I'm wondering why in a service defined as

  Service
    URL "^/atmdoc"
    Session
      Type IP
      TTL 300
    End
    BackEnd
      Address 10.0.10.66
      Port 80
    End
  End

the URL "http://www.myserver.com/atmdoc/"
does match, but without the
trailing slash, "http://www.myserver.com/atmdoc", the
service pattern
does not seem to match.

So how should I form the pattern to match also without the trailing slash?

Cheers,
Andreas.

RE: [Pound Mailing List] Matching URL pattern in Service definition
Joe Gooch <mrwizard(at)k12system.com>
2012-01-02 16:07:06 [ FULL ]
Both of those URLs would match.

Are you sure you're not seeing some other behavior? (i.e. URL with no-slash
would cause a normal webserver like apache to send a redirect, which may or may
not succeed depending on your redirect rewrite settings... But that wouldn't be
a problem with your URL matching.)

Joe

[...]

Re: [Pound Mailing List] Matching URL pattern in Service definition
"Andreas H." <lists(at)hilboll.de>
2012-01-02 18:58:48 [ FULL ]
Joe,

thanks for you input, and of course, you were right. For those who are
interested: I fixed the problem by adding the following to my Apache config:

        RedirectMatch ^/atmdoc$ /atmdoc/

Cheers,
Andreas.

Am 02.01.2012 16:07, schrieb Joe Gooch:[...][...]

MailBoxer