cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Andrew Savory <and...@luminas.co.uk>
Subject Re: Url to virtual host - rewrite rule
Date Thu, 02 Jan 2003 10:16:46 GMT

Hi Fred,

On Mon, 30 Dec 2002, Fred Vos wrote:

> Just found out myself that the following VirtualHost entry works:
>
> <VirtualHost *>
> ServerName www.mokolo.com
> DocumentRoot /opt/jakarta/tomcat/webapps
> JkMount /* ajp13
> ErrorLog /var/log/httpd/mokolo.com/error_log
> CustomLog /var/log/httpd/mokolo.com/access_log common
> RewriteEngine On
> RewriteRule (.*) /cocoon/mokolo$1 [PT]
> </VirtualHost>
>
> I removed '/cocoon' from the basedir and changed the RewriteRule.

If you put your example site in the mount/ directory of cocoon, there is
no need to edit the cocoon sitemap. The following will then work, too:

<VirtualHost ip.of.mokolo.com>
        ServerName www.mokolo.com
        RewriteEngine on
        RewriteLog /var/log/apache/rewrite.log
        RewriteLogLevel 9

        RewriteCond ${REQUEST_URI} !/mount/mokolo/.*
        RewriteRule ^(.*)/$ /mount/mokolo$1/index.html [PT]
        RewriteCond ${REQUEST_URI} !/mount/mokolo/.*
        RewriteRule ^/(.*[^/]) /mount/mokolo/$1 [PT]

        JkMount /* ajp13
</VirtualHost>

Hope that helps,

Andrew.

-- 
Andrew Savory                                Email: andrew@luminas.co.uk
Managing Director                              Tel:  +44 (0)870 741 6658
Luminas Internet Applications                  Fax:  +44 (0)700 598 1135
This is not an official statement or order.    Web:    www.luminas.co.uk


---------------------------------------------------------------------
Please check that your question  has not already been answered in the
FAQ before posting.     <http://xml.apache.org/cocoon/faq/index.html>

To unsubscribe, e-mail:     <cocoon-users-unsubscribe@xml.apache.org>
For additional commands, e-mail:   <cocoon-users-help@xml.apache.org>


Mime
View raw message