brooklyn-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alex Heneveld <alex.henev...@cloudsoftcorp.com>
Subject Re: Context root of an application in a YAML blueprint
Date Mon, 26 May 2014 12:03:23 GMT

Hi Maneesh,

You can use the "wars" flag to give a list of WAR files which will be 
installed based on their name, or "warsByContext" to specify the context 
path.

Here are an example of each:

services:
- serviceType: brooklyn.entity.webapp.tomcat.TomcatServer
    wars:
      - file:///tmp/HelloWorld.war
      - file:///tmp/goodbye.war

services:
- serviceType: brooklyn.entity.webapp.tomcat.TomcatServer
    warsByContext:
      HelloWorld: file:///tmp/HelloWorld.war
      goodbye: file:///tmp/goodbye.war

In the latter example you can put "/" as the key for a WAR to install it 
as the root war.

Best
Alex


On 24/05/2014 13:39, Maneesh Mehra wrote:
> Hi:
>
> I trying to understand how I can set the context root of a sample
> application that needs to run inside a Tomcat server ? Here is the YAML
> blueprint I have so far:
>
> name: HelloWorld
> location: localhost
> services:
> - serviceType: brooklyn.entity.webapp.tomcat.TomcatServer
>    name: HelloWorld
>    brooklyn.config:
>       wars.root: file:///tmp/HelloWorld.war
>       http.port: 9080
>
> When I deploy this application, brooklyn puts the HelloWorld.war as
> ROOT.war under .../tomcat/webapps folder. As a result, the application runs
> under root of the server. I would like to provide the application with a
> context root (like /Hello) so that it shows up on the server as:
> http:<server>:9080/Hello
>
> Thanks,
>
> Maneesh
>


Mime
View raw message