Is that possible to setup CouchDB enabled website URL mapping without Apache as reverse proxy?

150 Views Asked by At

Actually I'm running this with Apache as reverse proxy in front of CouchDB:

<VirtualHost *:80>
        ServerName abc.com
        ServerAlias www.abc.com

        ProxyPass /abc http://localhost:5984/abc
        ProxyPassReverse /abc http://localhost:5984/abc

        ProxyPass /_session http://localhost:5984/_session
        ProxyPassReverse /_session http://localhost:5984/_session

        ProxyPass / http://localhost:5984/abc/_design/tt/_rewrite/
        ProxyPassReverse / http://localhost:5984/abc/_design/tt/_rewrite/

</VirtualHost>

Is that possible to setup [vhosts] inside CouchDB itself to run it without Apache reverse proxy at front?

1

There are 1 best solutions below

0
On

vhosts work with the Host HTTP header for routing primarilly.

Combine that with rewrite rules (they are part of design documents) to accomplish what you are seeking to do.