pom.xml 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306
  1. <?xml version="1.0"?>
  2. <!--
  3. Licensed to the Apache Software Foundation (ASF) under one or more
  4. contributor license agreements. See the NOTICE file distributed with
  5. this work for additional information regarding copyright ownership.
  6. The ASF licenses this file to You under the Apache License, Version 2.0
  7. (the "License"); you may not use this file except in compliance with
  8. the License. You may obtain a copy of the License at
  9. http://www.apache.org/licenses/LICENSE-2.0
  10. Unless required by applicable law or agreed to in writing, software
  11. distributed under the License is distributed on an "AS IS" BASIS,
  12. WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  13. See the License for the specific language governing permissions and
  14. limitations under the License.
  15. -->
  16. <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/maven-v4_0_0.xsd">
  17. <modelVersion>4.0.0</modelVersion>
  18. <groupId>org.apache.ambari</groupId>
  19. <artifactId>ambari</artifactId>
  20. <packaging>pom</packaging>
  21. <name>Ambari Main</name>
  22. <version>1.3.0-SNAPSHOT</version>
  23. <description>Ambari</description>
  24. <properties>
  25. <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
  26. <clover.license>${user.home}/clover.license</clover.license>
  27. <buildnumber-maven-plugin-version>1.2</buildnumber-maven-plugin-version>
  28. <deb.publisher>Hortonworks</deb.publisher>
  29. <deb.section>universe/admin</deb.section>
  30. <deb.architecture>i386 amd64</deb.architecture>
  31. <deb.priority>extra</deb.priority>
  32. </properties>
  33. <pluginRepositories>
  34. <pluginRepository>
  35. <id>maven2-repository.dev.java.net</id>
  36. <name>Java.net Repository for Maven</name>
  37. <url>http://download.java.net/maven/2/</url>
  38. <layout>default</layout>
  39. </pluginRepository>
  40. <pluginRepository>
  41. <id>maven2-repository.atlassian</id>
  42. <name>Atlassian Maven Repository</name>
  43. <url>https://maven.atlassian.com/repository/public</url>
  44. <layout>default</layout>
  45. </pluginRepository>
  46. <pluginRepository>
  47. <id>maven2-glassfish-repository.dev.java.net</id>
  48. <name>Java.net Repository for Maven</name>
  49. <url>http://download.java.net/maven/glassfish/</url>
  50. </pluginRepository>
  51. </pluginRepositories>
  52. <build>
  53. <pluginManagement>
  54. <plugins>
  55. <plugin>
  56. <groupId>org.apache.rat</groupId>
  57. <artifactId>apache-rat-plugin</artifactId>
  58. <version>0.10</version>
  59. </plugin>
  60. <plugin>
  61. <groupId>org.apache.maven.plugins</groupId>
  62. <artifactId>maven-surefire-plugin</artifactId>
  63. <version>2.12</version>
  64. </plugin>
  65. <plugin>
  66. <groupId>org.codehaus.mojo</groupId>
  67. <artifactId>rpm-maven-plugin</artifactId>
  68. <version>2.0.1</version>
  69. </plugin>
  70. <plugin>
  71. <groupId>org.vafer</groupId>
  72. <artifactId>jdeb</artifactId>
  73. </plugin>
  74. </plugins>
  75. </pluginManagement>
  76. <plugins>
  77. <plugin>
  78. <groupId>org.codehaus.mojo</groupId>
  79. <artifactId>build-helper-maven-plugin</artifactId>
  80. <version>1.8</version>
  81. <executions>
  82. <execution>
  83. <id>parse-package-version</id>
  84. <goals>
  85. <goal>regex-property</goal>
  86. </goals>
  87. <configuration>
  88. <name>package-version</name>
  89. <value>${project.version}</value>
  90. <regex>^([0-9]+)\.([0-9]+)\.([0-9]+)(\.|-).*</regex>
  91. <replacement>$1.$2.$3</replacement>
  92. <failIfNoMatch>true</failIfNoMatch>
  93. </configuration>
  94. </execution>
  95. <execution>
  96. <id>parse-package-release</id>
  97. <goals>
  98. <goal>regex-property</goal>
  99. </goals>
  100. <configuration>
  101. <name>package-release</name>
  102. <value>${project.version}</value>
  103. <regex>^([0-9]+)\.([0-9]+)\.([0-9]+)(\.|-)(([0-9]+)|(SNAPSHOT)).*</regex>
  104. <replacement>$5</replacement>
  105. <failIfNoMatch>true</failIfNoMatch>
  106. </configuration>
  107. </execution>
  108. </executions>
  109. </plugin>
  110. <plugin>
  111. <groupId>org.apache.maven.plugins</groupId>
  112. <artifactId>maven-compiler-plugin</artifactId>
  113. <version>3.0</version>
  114. <configuration>
  115. <source>1.6</source>
  116. <target>1.6</target>
  117. </configuration>
  118. </plugin>
  119. <plugin>
  120. <artifactId>maven-assembly-plugin</artifactId>
  121. <configuration>
  122. <descriptors>
  123. <descriptor>ambari-project/src/main/assemblies/empty.xml</descriptor>
  124. </descriptors>
  125. </configuration>
  126. <executions>
  127. <execution>
  128. <id>make-assembly</id>
  129. <phase>package</phase>
  130. <goals>
  131. <goal>single</goal>
  132. </goals>
  133. </execution>
  134. </executions>
  135. </plugin>
  136. <plugin>
  137. <groupId>org.codehaus.mojo</groupId>
  138. <artifactId>rpm-maven-plugin</artifactId>
  139. <version>2.0.1</version>
  140. <executions>
  141. <execution>
  142. <!-- unbinds rpm creation from maven lifecycle -->
  143. <phase>none</phase>
  144. <goals>
  145. <goal>attached-rpm</goal>
  146. </goals>
  147. </execution>
  148. </executions>
  149. <configuration>
  150. <copyright>2012, Apache Software Foundation</copyright>
  151. <group>Development</group>
  152. <description>Maven Recipe: RPM Package.</description>
  153. <release>${package-release}</release>
  154. <version>${package-version}</version>
  155. <mappings/>
  156. </configuration>
  157. </plugin>
  158. <plugin>
  159. <groupId>org.apache.rat</groupId>
  160. <artifactId>apache-rat-plugin</artifactId>
  161. <configuration>
  162. <excludes>
  163. <exclude>**/*.json</exclude>
  164. <exclude>**/*.svg</exclude>
  165. <exclude>derby.log</exclude>
  166. <exclude>CHANGES.txt</exclude>
  167. <exclude>pass.txt</exclude>
  168. <exclude>contrib/addons/test/dataServices/jmx/data/cluster_configuration.json.nohbase</exclude>
  169. <exclude>contrib/ambari-scom/msi/src/GUI_Ambari.sln</exclude>
  170. <exclude>version</exclude>
  171. <!--IDE and GIT files-->
  172. <exclude>.idea/</exclude>
  173. <exclude>.git/</exclude>
  174. <exclude>**/.gitignore</exclude>
  175. <exclude>**/.gitattributes</exclude>
  176. <!--gitignore content-->
  177. <exclude>.DS_Store</exclude>
  178. <exclude>.iml/</exclude>
  179. <exclude>.classpath</exclude>
  180. <exclude>.project</exclude>
  181. <exclude>.settings</exclude>
  182. <exclude>*.pyc</exclude>
  183. <exclude>*.py~</exclude>
  184. <exclude>.hg</exclude>
  185. <exclude>.hgignore</exclude>
  186. <exclude>.hgtags</exclude>
  187. <!--Python Mock library (BSD license)-->
  188. <exclude>ambari-common/src/test/python/mock/**</exclude>
  189. <!--Jinja2 library (BSD license)-->
  190. <exclude>ambari-common/src/main/python/jinja2/**</exclude>
  191. <!--Contributions-->
  192. <exclude>contrib/ambari-scom/management-pack/Hadoop_MP/**</exclude>
  193. <exclude>contrib/addons/test/dataServices/jmx/data/cluster_configuration.json.nohbase</exclude>
  194. <exclude>contrib/ambari-scom/msi/src/GUI_Ambari.sln</exclude>
  195. <exclude>contrib/views/pig/src/main/resources/ui/pig-web/vendor/*</exclude>
  196. </excludes>
  197. </configuration>
  198. <executions>
  199. <execution>
  200. <phase>test</phase>
  201. <goals>
  202. <goal>check</goal>
  203. </goals>
  204. </execution>
  205. </executions>
  206. </plugin>
  207. <plugin>
  208. <groupId>org.vafer</groupId>
  209. <artifactId>jdeb</artifactId>
  210. <version>1.0.1</version>
  211. <executions>
  212. <execution>
  213. <phase>none</phase>
  214. <goals>
  215. <goal>jdeb</goal>
  216. </goals>
  217. </execution>
  218. </executions>
  219. <configuration>
  220. <skip>true</skip>
  221. <attach>false</attach>
  222. <submodules>true</submodules>
  223. <controlDir>${basedir}/ambari-project/src/main/package/deb/control</controlDir>
  224. </configuration>
  225. </plugin>
  226. </plugins>
  227. </build>
  228. <profiles>
  229. <profile>
  230. <id>default</id>
  231. <activation>
  232. <activeByDefault>true</activeByDefault>
  233. </activation>
  234. <modules>
  235. <module>ambari-web</module>
  236. <module>ambari-project</module>
  237. <module>ambari-views</module>
  238. <module>ambari-server</module>
  239. <module>ambari-agent</module>
  240. <module>ambari-client</module>
  241. </modules>
  242. </profile>
  243. <profile>
  244. <id>static-web</id>
  245. <modules>
  246. <module>ambari-project</module>
  247. <module>ambari-views</module>
  248. <module>ambari-server</module>
  249. <module>ambari-agent</module>
  250. <module>ambari-client</module>
  251. </modules>
  252. </profile>
  253. <profile>
  254. <id>clover</id>
  255. <activation>
  256. <activeByDefault>false</activeByDefault>
  257. <property>
  258. <name>clover</name>
  259. </property>
  260. </activation>
  261. <properties>
  262. <maven.clover.licenseLocation>${clover.license}</maven.clover.licenseLocation>
  263. <clover.version>3.1.11</clover.version>
  264. </properties>
  265. <build>
  266. <plugins>
  267. <plugin>
  268. <groupId>com.atlassian.maven.plugins</groupId>
  269. <artifactId>maven-clover2-plugin</artifactId>
  270. <version>${clover.version}</version>
  271. <configuration>
  272. <includesAllSourceRoots>true</includesAllSourceRoots>
  273. <includesTestSourceRoots>true</includesTestSourceRoots>
  274. <targetPercentage>50%</targetPercentage>
  275. <generateHtml>true</generateHtml>
  276. <generateXml>true</generateXml>
  277. <excludes>
  278. <exclude>**/generated/**</exclude>
  279. </excludes>
  280. </configuration>
  281. <executions>
  282. <execution>
  283. <id>clover-setup</id>
  284. <phase>process-sources</phase>
  285. <goals>
  286. <goal>setup</goal>
  287. </goals>
  288. </execution>
  289. <execution>
  290. <id>clover</id>
  291. <phase>test</phase>
  292. <goals>
  293. <goal>clover</goal>
  294. </goals>
  295. </execution>
  296. </executions>
  297. </plugin>
  298. </plugins>
  299. </build>
  300. </profile>
  301. </profiles>
  302. </project>