camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Andrew Block <>
Subject Re: Karaf ConfigFile question
Date Mon, 20 Oct 2014 13:50:16 GMT

It depends how you architect your maven projects, but lets just say for example you have a
two maven projects (bundle and feature). Your bundle will contain the corresponding .cfg file.
The Maven Build Helper Plugin can be used with the attach-artifact goal. This will install
the configuration file into your local maven repository using a type and classifier. Make
sure you specify an executions section and the appropriate phase you would like it to run
during the course of your build.

In your feature file, you can then reference the resource in the maven repository similar
to the following:

<configfile finalname="/etc/bundle.cfg">mvn:<groupId>/<artifactId>/<version>/<type>/<classifier></configfile>

- Andy

Andrew Block

On October 20, 2014 at 8:17:14 AM, rhuiser ( wrote:


I am using Maven camel-archetype-blueprint to develop routes for the OSGi  
Karaf container.  
I would like to deploy the bundle together with a default configuration.  
This can be done using a Karaf feature file.  

When manually creating the feature and bundle configuration (without using  
Maven), it is possible to add a configfile element:  

Question is...  
* Where in the Maven project should I add the MyTestConfig.cfg file?  
* How do I add the configFile section to the feature automatically when  
performing a "mvn install" ?  

Thanks in advance,  

View this message in context:
Sent from the Camel - Users mailing list archive at  

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message