Hi all,
I've problem to rewrite cookie path and cookie domain in HAproxy; I've a
Nginx configuration but I want to move from Nginx to HAProxy for this proxy
pass.
This is a Nginx config I want to replace:
location /~xxx/ {
proxy_cookie_domain ~.* .$site.it;
proxy_cookie_path ~.* /~xxx/;
proxy_set_header Host $site.it;
proxy_pass http://192.168.1.2/;
}
I need same function of proxy_cookie_domain and proxy_cookie_path; I found
this:
http://blog.haproxy.com/2014/04/28/howto-write-apache-proxypass-rules-in-haproxy/
but not work form me.
Now I can change cookie path with:
rspirep ^(Set-Cookie:.*)\ path=(.*) \1\ path=/~xxx/
I need add also domain, only if exists, but with dynamic hostname; I;ve
tried with
acl hdr_set_cookie_domain_and_path res.hdr(Set-cookie) -m sub domain=
res.hdr(Set-cookie) -m sub path=
rspirep ^(Set-Cookie:.*)\ path=(.*) \1\ path=/~xxx/;\ domain=%[hdr(Host)]
if hdr_set_cookie_domain_and_path
But not work.
Anyone can help me?
Tnx,
rr
2015-07-14 21:34 GMT+02:00 Baptiste <[email protected]>:
> Please repost your question. I can't see it in my mail history.
>
> Baptiste
>
> On Tue, Jul 14, 2015 at 3:33 PM, rickytato rickytato
> <[email protected]> wrote:
> > Anyone can help me? I keep using Nginx?
> >
> > 2015-07-07 10:46 GMT+02:00 rickytato rickytato <
> [email protected]>:
> >>
> >> 1.5.12
> >>
> >> 2015-07-06 17:58 GMT+02:00 Aleksandar Lazic <[email protected]>:
> >>>
> >>> Dear rickytato rickytato.
> >>>
> >>> Am 06-07-2015 15:32, schrieb rickytato rickytato:
> >>>
> >>>> Hi all,
> >>>> I've problem to rewrite cookie path and cookie domain in HAproxy;
> I've a
> >>>> Nginx configuration but I want to move from Nginx to HAProxy for this
> proxy
> >>>> pass.
> >>>
> >>>
> >>> Which Version of haproxy do you use?
> >>>
> >>> haproxy -vv ?
> >>>
> >>> Cheers Aleks
> >>
> >>
> >
>