pom.xml 8.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189
  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>com.scytl.products.ov.channel.ei</groupId>
  6. <artifactId>election-information</artifactId>
  7. <version>2.1.7</version>
  8. </parent>
  9. <groupId>com.scytl.products.ov.channel.ei.ui</groupId>
  10. <artifactId>ei-ws-rest</artifactId>
  11. <packaging>war</packaging>
  12. <name>Online Voting - Election Information - Webservices</name>
  13. <dependencyManagement>
  14. <dependencies>
  15. <dependency>
  16. <groupId>com.scytl.products.ov.channel.commons</groupId>
  17. <artifactId>ov-commons-integration-tests</artifactId>
  18. <version>${project.version}</version>
  19. <scope>import</scope>
  20. <type>pom</type>
  21. </dependency>
  22. </dependencies>
  23. </dependencyManagement>
  24. <dependencies>
  25. <!-- Local dependencies -->
  26. <dependency>
  27. <groupId>com.scytl.products.ov.channel.ei.service</groupId>
  28. <artifactId>election-information-services</artifactId>
  29. <version>${project.version}</version>
  30. </dependency>
  31. <!-- OV CHANNEL COMMONS -->
  32. <dependency>
  33. <groupId>com.scytl.products.ov.channel.commons</groupId>
  34. <artifactId>ov-commons-infrastructure</artifactId>
  35. </dependency>
  36. <!-- JERSEY -->
  37. <dependency>
  38. <groupId>org.glassfish.jersey.test-framework</groupId>
  39. <artifactId>jersey-test-framework-core</artifactId>
  40. <version>${jersey-test-framework-core.version}</version>
  41. <scope>test</scope>
  42. </dependency>
  43. <dependency>
  44. <groupId>org.glassfish.jersey.test-framework.providers</groupId>
  45. <artifactId>jersey-test-framework-provider-grizzly2</artifactId>
  46. <version>${jersey-test-framework-core.version}</version>
  47. <scope>test</scope>
  48. </dependency>
  49. <dependency>
  50. <groupId>org.glassfish.jersey.media</groupId>
  51. <artifactId>jersey-media-json-jackson</artifactId>
  52. <version>${jersey-test-framework-core.version}</version>
  53. <scope>test</scope>
  54. </dependency>
  55. <!-- INTEGRATION TESTS (keep the dependency position to avoid incompatibilities with JAX-RS)-->
  56. <dependency>
  57. <groupId>com.scytl.products.ov.channel.commons</groupId>
  58. <artifactId>ov-commons-integration-tests</artifactId>
  59. <version>${project.version}</version>
  60. <scope>test</scope>
  61. </dependency>
  62. <dependency>
  63. <groupId>com.oracle</groupId>
  64. <artifactId>ojdbc8</artifactId>
  65. <version>${oracle-driver.version}</version>
  66. <scope>test</scope>
  67. </dependency>
  68. </dependencies>
  69. <build>
  70. <finalName>${project.artifactId}</finalName>
  71. <plugins>
  72. <plugin>
  73. <artifactId>maven-war-plugin</artifactId>
  74. <version>${maven-war-plugin.version}</version>
  75. <configuration>
  76. <attachClasses>true</attachClasses>
  77. </configuration>
  78. </plugin>
  79. <!-- Generates a jar with the junits that can be reused in other modules -->
  80. <plugin>
  81. <groupId>org.apache.maven.plugins</groupId>
  82. <artifactId>maven-jar-plugin</artifactId>
  83. <version>2.6</version>
  84. <executions>
  85. <execution>
  86. <goals>
  87. <goal>test-jar</goal>
  88. </goals>
  89. </execution>
  90. </executions>
  91. </plugin>
  92. </plugins>
  93. </build>
  94. <!-- The profile below can be used if the HTML API files should be generated -->
  95. <!-- It includes the installation of node, npm and raml2html -->
  96. <profiles>
  97. <profile>
  98. <id>skipTestRun</id>
  99. <activation>
  100. <property>
  101. <name>skipTests</name>
  102. <value>!true</value>
  103. </property>
  104. </activation>
  105. <dependencies>
  106. <dependency>
  107. <groupId>com.scytl.products.ov.channel.commons.lib</groupId>
  108. <artifactId>ov-commons-lib</artifactId>
  109. <type>test-jar</type>
  110. <scope>test</scope>
  111. </dependency>
  112. </dependencies>
  113. </profile>
  114. <profile>
  115. <id>generate-all-html-apis</id>
  116. <build>
  117. <finalName>${project.artifactId}</finalName>
  118. <plugins>
  119. <plugin>
  120. <groupId>com.github.eirslett</groupId>
  121. <artifactId>frontend-maven-plugin</artifactId>
  122. <version>${frontend-maven-plugin.version}</version>
  123. <!-- install local installation of node and npm in the target directory -->
  124. <configuration>
  125. <installDirectory>target</installDirectory>
  126. </configuration>
  127. <executions>
  128. <execution>
  129. <id>install node and npm</id>
  130. <goals>
  131. <goal>install-node-and-npm</goal>
  132. </goals>
  133. <configuration>
  134. <nodeVersion>${node.version}</nodeVersion>
  135. <npmVersion>${npm.version}</npmVersion>
  136. <nodeDownloadRoot>
  137. https://nexus.scytl.net/service/local/repositories/applications/content/org/nodejs/node/
  138. </nodeDownloadRoot>
  139. <npmDownloadRoot>
  140. https://nexus.scytl.net/service/local/repositories/applications/content/com/github/npm/npm/
  141. </npmDownloadRoot>
  142. </configuration>
  143. </execution>
  144. </executions>
  145. </plugin>
  146. <plugin>
  147. <groupId>org.codehaus.mojo</groupId>
  148. <artifactId>exec-maven-plugin</artifactId>
  149. <executions>
  150. <!-- Install raml2html -->
  151. <execution>
  152. <id>id0</id>
  153. <phase>package</phase>
  154. <goals>
  155. <goal>exec</goal>
  156. </goals>
  157. <configuration>
  158. <executable>npm</executable>
  159. <commandlineArgs>install --prefix ./target/node/node_modules/npm-${npm.version}
  160. raml2html
  161. </commandlineArgs>
  162. </configuration>
  163. </execution>
  164. <!-- Generate API file -->
  165. <execution>
  166. <id>id1</id>
  167. <phase>package</phase>
  168. <goals>
  169. <goal>exec</goal>
  170. </goals>
  171. <configuration>
  172. <executable>target/node/node_modules/npm-${npm.version}/node_modules/raml2html/bin/raml2html</executable>
  173. <commandlineArgs>-i src/main/resources/api.raml -o target/api.html</commandlineArgs>
  174. </configuration>
  175. </execution>
  176. </executions>
  177. </plugin>
  178. </plugins>
  179. </build>
  180. </profile>
  181. </profiles>
  182. </project>