I did not use any specific goal as I used karaf-assembly packaging which automatically calls install-kars and instance-create-archive goals.
I have a custom org.ops4j.pax.logging.cfg in the file in src/main/resources/etc/. I have attached the built zip file in this mail. You will find 2 files named org.ops4j.pax.logging.cfg in etc folder. Here is my pom.xml : <?xml version="1.0" encoding="UTF-8"?> <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM http://maven.apache.org/xsd/maven-4.0.0.xsd"> <modelVersion>4.0.0</modelVersion> <groupId>test</groupId> <artifactId>test-custom</artifactId> <version>1.0.0-SNAPSHOT</version> <packaging>karaf-assembly</packaging> <name>${project.artifactId}</name> <properties> <karaf.version>3.0.0</karaf.version> </properties> <dependencies> <dependency> <!-- scope is compile so all features (there is only one) are installed into startup.properties and the feature repo itself is not installed --> <groupId>org.apache.karaf.features</groupId> <artifactId>framework</artifactId> <version>${karaf.version}</version> <type>kar</type> </dependency> <dependency> <!-- scope is runtime so the feature repo is listed in the features service config file, and features may be installed using the karaf-maven-plugin configuration --> <groupId>org.apache.karaf.features</groupId> <artifactId>standard</artifactId> <classifier>features</classifier> <version>${karaf.version}</version> <type>xml</type> <scope>runtime</scope> </dependency> </dependencies> <build> <plugins> <plugin> <groupId>org.apache.karaf.tooling</groupId> <artifactId>karaf-maven-plugin</artifactId> <version>3.0.0</version> <extensions>true</extensions> <configuration> <!-- no startupFeatures --> <bootFeatures> <feature>standard</feature> <feature>management</feature> </bootFeatures> <!-- no installedFeatures --> </configuration> </plugin> </plugins> </build> </project> -- Nicolas Dutertry -----Original Message----- From: Jean-Baptiste Onofré [mailto:[email protected]] Sent: mardi 4 mars 2014 09:57 To: [email protected] Subject: Re: karaf-assembly and config files Hi Nicolas, Did you create a kar file with the create-kar goal and use the install-kar goal to populate the assembly ? Could you explain what you do ? Thanks, Regards JB On 03/04/2014 09:27 AM, Dutertry Nicolas wrote: > Hi, > > I am using karaf-assembly packaging to build a custom karaf distribution with > karaf-maven-plugin. > > What is the right way to override the content of a standard karaf file ? For > instance I want to provide a custom org.ops4j.pax.logging.cfg. > > I tried to put the file in src/main/resources/etc/org.ops4j.pax.logging.cfg, > but then the final zip contains the file twice in "etc" folder (mine plus the > original one). > > Regards, > -- Jean-Baptiste Onofré [email protected] http://blog.nanthrax.net Talend - http://www.talend.com
ScanMail detected and removed a file named "test-custom-1.0.0-SNAPSHOT.zip" that violated attachment blocking policy from the original mail entity. You can safely save or delete this replacement attachment.
