Added features-test for base Karaf features and fixed some minor issues that caused...
[controller.git] / opendaylight / distribution / opendaylight-karaf / pom.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <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/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
3   <modelVersion>4.0.0</modelVersion>
4   <parent>
5     <groupId>org.opendaylight.controller</groupId>
6     <artifactId>commons.opendaylight</artifactId>
7     <version>1.4.2-SNAPSHOT</version>
8     <relativePath>../../commons/opendaylight</relativePath>
9   </parent>
10   <artifactId>distribution.opendaylight-karaf</artifactId>
11   <packaging>pom</packaging>
12   <prerequisites>
13     <maven>3.0</maven>
14   </prerequisites>
15
16   <dependencies>
17     <dependency>
18       <!-- scope is compile so all features (there is only one) are installed
19             into startup.properties and the feature repo itself is not installed -->
20       <groupId>org.apache.karaf.features</groupId>
21       <artifactId>framework</artifactId>
22       <version>${karaf.version}</version>
23       <type>kar</type>
24     </dependency>
25     <dependency>
26       <groupId>org.opendaylight.controller</groupId>
27       <artifactId>karaf.branding</artifactId>
28       <scope>compile</scope>
29     </dependency>
30
31     <!-- Resources needed -->
32     <dependency>
33       <groupId>org.opendaylight.controller</groupId>
34       <artifactId>opendaylight-karaf-resources</artifactId>
35       <version>${project.version}</version>
36     </dependency>
37
38     <!-- scope is not runtime so the feature repo is pulled into the local
39     repo on build and thus you actually run.  Failure to do so can lead
40     to very confusing errors for devs -->
41     <dependency>
42       <groupId>org.apache.karaf.features</groupId>
43       <artifactId>standard</artifactId>
44       <version>${karaf.version}</version>
45       <classifier>features</classifier>
46       <type>xml</type>
47     </dependency>
48
49     <!--
50           controller provided features:
51           Note: Nothing should go here that is not locked
52           down with testing... ie, no broken feature repos
53     -->
54
55     <!-- MD-SAL Related Features -->
56     <dependency>
57       <groupId>org.opendaylight.controller</groupId>
58       <artifactId>features-base</artifactId>
59       <classifier>features</classifier>
60       <type>xml</type>
61     </dependency>
62     <dependency>
63       <groupId>org.opendaylight.controller</groupId>
64       <artifactId>features-mdsal</artifactId>
65       <classifier>features</classifier>
66       <type>xml</type>
67     </dependency>
68     <dependency>
69       <groupId>org.opendaylight.controller</groupId>
70       <artifactId>features-flow</artifactId>
71       <classifier>features</classifier>
72       <type>xml</type>
73     </dependency>
74   </dependencies>
75
76   <build>
77     <pluginManagement>
78       <plugins>
79         <plugin>
80           <groupId>org.eclipse.m2e</groupId>
81           <artifactId>lifecycle-mapping</artifactId>
82           <version>1.0.0</version>
83           <configuration>
84             <lifecycleMappingMetadata>
85               <pluginExecutions>
86                 <pluginExecution>
87                   <pluginExecutionFilter>
88                     <groupId>org.apache.felix</groupId>
89                     <artifactId>maven-bundle-plugin</artifactId>
90                     <versionRange>[0,)</versionRange>
91                     <goals>
92                       <goal>cleanVersions</goal>
93                     </goals>
94                   </pluginExecutionFilter>
95                   <action>
96                     <ignore></ignore>
97                   </action>
98                 </pluginExecution>
99                 <pluginExecution>
100                   <pluginExecutionFilter>
101                     <groupId>org.apache.maven.plugins</groupId>
102                     <artifactId>maven-dependency-plugin</artifactId>
103                     <versionRange>[0,)</versionRange>
104                     <goals>
105                       <goal>copy</goal>
106                       <goal>unpack</goal>
107                     </goals>
108                   </pluginExecutionFilter>
109                   <action>
110                     <ignore></ignore>
111                   </action>
112                 </pluginExecution>
113                 <pluginExecution>
114                   <pluginExecutionFilter>
115                     <groupId>org.apache.karaf.tooling</groupId>
116                     <artifactId>karaf-maven-plugin</artifactId>
117                     <versionRange>[0,)</versionRange>
118                     <goals>
119                       <goal>commands-generate-help</goal>
120                     </goals>
121                   </pluginExecutionFilter>
122                   <action>
123                     <ignore></ignore>
124                   </action>
125                 </pluginExecution>
126                 <pluginExecution>
127                   <pluginExecutionFilter>
128                     <groupId>org.fusesource.scalate</groupId>
129                     <artifactId>maven-scalate-plugin</artifactId>
130                     <versionRange>[0,)</versionRange>
131                     <goals>
132                       <goal>sitegen</goal>
133                     </goals>
134                   </pluginExecutionFilter>
135                   <action>
136                     <ignore></ignore>
137                   </action>
138                 </pluginExecution>
139                 <pluginExecution>
140                   <pluginExecutionFilter>
141                     <groupId>org.apache.servicemix.tooling</groupId>
142                     <artifactId>depends-maven-plugin</artifactId>
143                     <versionRange>[0,)</versionRange>
144                     <goals>
145                       <goal>generate-depends-file</goal>
146                     </goals>
147                   </pluginExecutionFilter>
148                   <action>
149                     <ignore></ignore>
150                   </action>
151                 </pluginExecution>
152               </pluginExecutions>
153             </lifecycleMappingMetadata>
154           </configuration>
155         </plugin>
156       </plugins>
157     </pluginManagement>
158     <plugins>
159       <plugin>
160         <groupId>org.apache.karaf.tooling</groupId>
161         <artifactId>karaf-maven-plugin</artifactId>
162         <version>${karaf.version}</version>
163         <extensions>true</extensions>
164         <configuration>
165           <!-- no startupFeatures -->
166           <bootFeatures>
167             <feature>standard</feature>
168           </bootFeatures>
169           <!-- no installedFeatures -->
170         </configuration>
171         <executions>
172           <execution>
173             <id>process-resources</id>
174             <goals>
175               <goal>install-kars</goal>
176             </goals>
177             <phase>process-resources</phase>
178           </execution>
179           <execution>
180             <id>package</id>
181             <goals>
182               <goal>instance-create-archive</goal>
183             </goals>
184           </execution>
185         </executions>
186       </plugin>
187       <plugin>
188         <groupId>org.apache.maven.plugins</groupId>
189         <artifactId>maven-checkstyle-plugin</artifactId>
190         <version>${checkstyle.version}</version>
191         <configuration>
192           <excludes>**\/target\/,**\/bin\/,**\/target-ide\/,**\/configuration\/initial\/</excludes>
193         </configuration>
194       </plugin>
195       <plugin>
196         <groupId>org.apache.maven.plugins</groupId>
197         <artifactId>maven-dependency-plugin</artifactId>
198         <version>2.6</version>
199         <executions>
200           <execution>
201             <id>copy</id>
202             <goals>
203               <goal>copy</goal>
204             </goals>
205             <!-- here the phase you need -->
206             <phase>generate-resources</phase>
207             <configuration>
208               <artifactItems>
209                 <artifactItem>
210                   <groupId>org.opendaylight.controller</groupId>
211                   <artifactId>karaf.branding</artifactId>
212                   <version>${karaf.branding.version}</version>
213                   <outputDirectory>target/assembly/lib</outputDirectory>
214                   <destFileName>karaf.branding-${branding.version}.jar</destFileName>
215                 </artifactItem>
216               </artifactItems>
217             </configuration>
218           </execution>
219           <execution>
220             <id>unpack-karaf-resources</id>
221             <goals>
222               <goal>unpack-dependencies</goal>
223             </goals>
224             <phase>prepare-package</phase>
225             <configuration>
226              <outputDirectory>${project.build.directory}/assembly</outputDirectory>
227              <groupId>org.opendaylight.controller</groupId>
228              <includeArtifactIds>opendaylight-karaf-resources</includeArtifactIds>
229              <excludes>META-INF\/**</excludes>
230              <excludeTransitive>true</excludeTransitive>
231              <ignorePermissions>false</ignorePermissions>
232             </configuration>
233           </execution>
234         </executions>
235       </plugin>
236       <plugin>
237         <groupId>org.apache.maven.plugins</groupId>
238         <artifactId>maven-antrun-plugin</artifactId>
239         <executions>
240             <execution>
241                 <phase>prepare-package</phase>
242                 <goals>
243                     <goal>run</goal>
244                 </goals>
245                 <configuration>
246                   <tasks>
247                     <chmod perm="755">
248                         <fileset dir="${project.build.directory}/assembly/bin">
249                           <include name="karaf"/>
250                           <include name="instance"/>
251                         </fileset>
252                     </chmod>
253                   </tasks>
254                 </configuration>
255             </execution>
256         </executions>
257       </plugin>
258     </plugins>
259   </build>
260   <scm>
261     <connection>scm:git:ssh://git.opendaylight.org:29418/controller.git</connection>
262     <developerConnection>scm:git:ssh://git.opendaylight.org:29418/controller.git</developerConnection>
263     <tag>HEAD</tag>
264     <url>https://wiki.opendaylight.org/view/OpenDaylight_Controller:Main</url>
265   </scm>
266 </project>