Robin,

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 ([email protected]) wrote:

Hi,  

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,  
Robin  




--  
View this message in context: 
http://camel.465427.n5.nabble.com/Karaf-ConfigFile-question-tp5757806.html  
Sent from the Camel - Users mailing list archive at Nabble.com.  

Reply via email to