> Le 15 juin 2015 à 01:16, Reyk Floeter <[email protected]> a écrit :
>
>> On 14.06.2015, at 18:08, Joel Carnat <[email protected]> wrote:
>>
>> Hi,
>>
>> I was going to install SOGo on OpenBSD 5.7 using the native httpd(8).
>> In the readme, there are configuration examples for nginx and
>> apache-httpd-openbsd. Nothing for the new httpd.
>> There are rewrite/redirect features that I can’t figure out how to setup
>> with httpd(8).
>>
>> nginx example:
>> location = /principals/
>> {
>> rewrite ^ http://$server_name/SOGo/dav;
>> allow all;
>> }
>>
>> apache-httpd-openbsd example:
>> RedirectMatch ^/principals/$ http://127.0.0.1:8800/SOGo/dav/
>>
>> Is it possible to achieve such feature with httpd and/or relayd ?
>>
>
> Kind of. You could try something like:
>
> location "/principals/" {
> block return 301 "http://$SERVER_NAME/SOGo/dav/"
> }
>
> Replace $SERVER_NAME with the IP, or add $SERVER_PORT, if required.
OK, thank you.
Now, part 2 ; is there a way to mimic the ProxyPass primitive ?
nginx example:
server {
listen 80;
location ^~/SOGo {
proxy_pass http://127.0.0.1:20000;
apache-httpd-openbsd example:
ProxyPass /SOGo http://127.0.0.1:20000/SOGo
ProxyPassReverse /SOGo http://127.0.0.1:20000/SOGo
That is, the browser thinks it is talking to httpd(8) on https://public.ip:443/
but the daemon forwards to internal hidden process.
Thanks.