If he meant that the cms should be available via multiple vhosts(apache2), but share the same application base then what?

Lets say:
mycompA.com --> myapplication on tomcat server via apache2
mycompB.com --> myapplication on tomcat server via apache2

using a vhost config some what like this:

<VirtualHost *:* >
ServerName mycompA.com
ServerAlias mycompB.com
ProxyPass / http://tomcatlocation+context/
ProxyPassReverse / http://tomcatlocation+context/
ProxyPassReverseCookiePath /context /
<Proxy *>
   Order deny,allow
   Allow from all
</Proxy>
</VirtualHost>
I guess WebRequest.getHttpServletRequest().xxxx picks that up too?

Maurice Marrink wrote:
If you place contextfiles in <tomcat_home>/conf/catalina/<host_name>
and place your war anywhere but in <tomcat_home>/webapps you can reuse
1 war for multiple applications. In each of the context files you
could then set a variable you can retrieve through jndi.

for example we have the following setup:
/conf/catalina/localhost
   -app1.xml
   -app2.xml
/deploy
   -app.war

There is just one trick you need to be aware of when you use log4j to
log to a file, but if you use tomcat logging or the console it should
be fine.

Maurice

On Wed, Mar 26, 2008 at 3:58 PM, Johan Compagner <[EMAIL PROTECTED]> wrote:
the host can maybe be get from the WebRequest.getHttpServletRequest().xxxx

 but you could be virtual hosted/behind apache or what ever

 so i would make the host name an configurable param.

 johan




 On Wed, Mar 26, 2008 at 3:30 PM, kman <[EMAIL PROTECTED]> wrote:

 >
 > to assign a style you must get the name of the host so basically i didnt
 > find
 > any way to do this inside session or somewhere else
 >
 > jwcarman wrote:
 > >
 > > Have you looked into Wicket's "skin" support?  Basically, you can
 > > assign a "style" to each session.
 > >
 > > On Wed, Mar 26, 2008 at 6:08 AM, kman <[EMAIL PROTECTED]> wrote:
 > >>
 > >>  i am currently working on a simple CMS based on wicket.
 > >>  I want the resulting application to support multiple sites based on
 > host
 > >>  name.
 > >>  i have a CustomResourceStreamLocator which lookups templates inside
 > >> WEB-INF
 > >>  folder.
 > >>  is there an easy way to customize ResourceStreamLocator to lookup html
 > >> files
 > >>  based on virtual host?
 > >>  for example html files for example.com to be in
 > >>  WEB-INF/templates/example.com
 > >>  and for example2.com to be in WEB-INF/templates/example2.com
 > >>  ?
 > >>  --
 > >>  View this message in context:
 > >>
 > 
http://www.nabble.com/Page-templates-per-virtual-host-tp16299142p16299142.html
 > >>  Sent from the Wicket - User mailing list archive at Nabble.com.
 > >>
 > >>
 > >>  ---------------------------------------------------------------------
 > >>  To unsubscribe, e-mail: [EMAIL PROTECTED]
 > >>  For additional commands, e-mail: [EMAIL PROTECTED]
 > >>
 > >>
 > >
 > > ---------------------------------------------------------------------
 > > To unsubscribe, e-mail: [EMAIL PROTECTED]
 > > For additional commands, e-mail: [EMAIL PROTECTED]
 > >
 > >
 > >
 >
 > --
 > View this message in context:
 > 
http://www.nabble.com/Page-templates-per-virtual-host-tp16299142p16301536.html
 > Sent from the Wicket - User mailing list archive at Nabble.com.
 >
 >
 > ---------------------------------------------------------------------
 > To unsubscribe, e-mail: [EMAIL PROTECTED]
 > For additional commands, e-mail: [EMAIL PROTECTED]
 >
 >


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



--
-Wicket for love

Nino Martinez Wael
Java Specialist @ Jayway DK
http://www.jayway.dk
+45 2936 7684


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to