Hi all,
I'm fairly new to cherokee, and I can't seem to find what I'm looking
for on the web.
I have an apache serving a subversion repository in plain HTTP. This
server sits behind a cherokee which acts as a reverse proxy and
offloads the SSL handling.
This setup works nicely for normal things like checkout and commit.
However, when I try to do a move, svn performs a WebDAV COPY, which
fails with a 502 - Bad gateway error.
I've been able to find that this is caused by a 'Destination' HTTP
header that is sent in the request. The WebDAV COPY works by using the
URL to which the request is sent as the FROM, and the value of the
Destination header as the TO. So my client sends something like this:
Host: https://server/svn/sourcefile, Destination:
https://server/svn/destinationfile
The problem, now, is that the reverse proxy only rewrites the host to
HTTP, and the destination is kept as is, giving the following:
Host: http://server/svn/sourcefile, Destination:
https://server/svn/destinationfile
Apache does not know how to deal with this, and fails on it.
The solution proposed on the net for cases where an apache is acting
as the reverse proxy for another apache server, is to perform a regexp
header rewrite on the Destination header, like so:
RequestHeader edit Destination ^https: http: early
This would cause the apache to see the following
Host: http://server/svn/sourcefile, Destination:
http://server/svn/destinationfile
Is there any way to do such a thing in Cherokee? I know how to add or
remove headers, but I haven't found any way of doing actual rewriting
using parts of the original header.
If there is another, better way to do this, I'd be glad to hear it, too.
Thanks in advance,
_______________________________________________
Cherokee-dev mailing list
Cherokee-dev@lists.octality.com
http://lists.octality.com/listinfo/cherokee-dev
I'm fairly new to cherokee, and I can't seem to find what I'm looking
for on the web.
I have an apache serving a subversion repository in plain HTTP. This
server sits behind a cherokee which acts as a reverse proxy and
offloads the SSL handling.
This setup works nicely for normal things like checkout and commit.
However, when I try to do a move, svn performs a WebDAV COPY, which
fails with a 502 - Bad gateway error.
I've been able to find that this is caused by a 'Destination' HTTP
header that is sent in the request. The WebDAV COPY works by using the
URL to which the request is sent as the FROM, and the value of the
Destination header as the TO. So my client sends something like this:
Host: https://server/svn/sourcefile, Destination:
https://server/svn/destinationfile
The problem, now, is that the reverse proxy only rewrites the host to
HTTP, and the destination is kept as is, giving the following:
Host: http://server/svn/sourcefile, Destination:
https://server/svn/destinationfile
Apache does not know how to deal with this, and fails on it.
The solution proposed on the net for cases where an apache is acting
as the reverse proxy for another apache server, is to perform a regexp
header rewrite on the Destination header, like so:
RequestHeader edit Destination ^https: http: early
This would cause the apache to see the following
Host: http://server/svn/sourcefile, Destination:
http://server/svn/destinationfile
Is there any way to do such a thing in Cherokee? I know how to add or
remove headers, but I haven't found any way of doing actual rewriting
using parts of the original header.
If there is another, better way to do this, I'd be glad to hear it, too.
Thanks in advance,
_______________________________________________
Cherokee-dev mailing list
Cherokee-dev@lists.octality.com
http://lists.octality.com/listinfo/cherokee-dev