Step version to 1.11.9-SNAPSHOT
[sdc.git] / utils / webseal-simulator / pom.xml
1 <project xmlns="http://maven.apache.org/POM/4.0.0"
2     xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
3     xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
4
5
6     <modelVersion>4.0.0</modelVersion>
7     <artifactId>webseal-simulator</artifactId>
8     <packaging>war</packaging>
9
10     <parent>
11         <groupId>org.openecomp.sdc</groupId>
12         <artifactId>sdc-main</artifactId>
13         <version>1.11.9-SNAPSHOT</version>
14         <relativePath>../../</relativePath>
15     </parent>
16
17     <properties>
18         <maven.build.timestamp.format>yyyyMMdd'T'HHmmss'Z'</maven.build.timestamp.format>
19         <nexus.proxy>https://nexus.onap.org</nexus.proxy>
20         <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
21         <sonar.skip>true</sonar.skip>
22     </properties>
23
24     <dependencies>
25         <dependency>
26             <groupId>javax.servlet</groupId>
27             <artifactId>javax.servlet-api</artifactId>
28             <version>${javax.servlet.version}</version>
29         </dependency>
30
31         <dependency>
32             <groupId>org.apache.httpcomponents</groupId>
33             <artifactId>httpclient</artifactId>
34             <version>${httpclient.version}</version>
35             <exclusions>
36                 <exclusion>
37                     <groupId>org.apache.httpcomponents</groupId>
38                     <artifactId>httpcore</artifactId>
39                 </exclusion>
40             </exclusions>
41         </dependency>
42         <dependency>
43             <groupId>org.apache.httpcomponents</groupId>
44             <artifactId>httpcore</artifactId>
45             <version>${httpcore.version}</version>
46         </dependency>
47
48         <dependency>
49             <groupId>org.apache.commons</groupId>
50             <artifactId>commons-lang3</artifactId>
51         </dependency>
52
53         <dependency>
54             <groupId>commons-logging</groupId>
55             <artifactId>commons-logging-api</artifactId>
56             <version>1.0.4</version>
57         </dependency>
58
59         <dependency>
60             <groupId>commons-io</groupId>
61             <artifactId>commons-io</artifactId>
62             <version>${commons.io.version}</version>
63         </dependency>
64
65         <dependency>
66             <groupId>commons-codec</groupId>
67             <artifactId>commons-codec</artifactId>
68             <version>${commons-codec}</version>
69             <scope>compile</scope>
70         </dependency>
71
72         <dependency>
73             <groupId>org.eclipse.jetty</groupId>
74             <artifactId>jetty-proxy</artifactId>
75             <version>${jetty.version}</version>
76             <scope>compile</scope>
77             <exclusions>
78                 <exclusion>
79                     <groupId>org.eclipse.jetty</groupId>
80                     <artifactId>jetty-http</artifactId>
81                 </exclusion>
82             </exclusions>
83         </dependency>
84
85         <dependency>
86             <groupId>org.eclipse.jetty</groupId>
87             <artifactId>jetty-servlets</artifactId>
88             <version>${jetty.version}</version>
89             <scope>compile</scope>
90             <exclusions>
91                 <exclusion>
92                     <groupId>org.eclipse.jetty</groupId>
93                     <artifactId>jetty-http</artifactId>
94                 </exclusion>
95             </exclusions>
96         </dependency>
97
98         <!-- Proxy servlet -->
99         <dependency>
100             <groupId>com.typesafe</groupId>
101             <artifactId>config</artifactId>
102             <version>1.0.2</version>
103             <scope>compile</scope>
104         </dependency>
105         <dependency>
106             <groupId>org.openecomp.sdc</groupId>
107             <artifactId>openecomp-sdc-logging-api</artifactId>
108             <version>${project.version}</version>
109             <exclusions>
110                 <exclusion>
111                     <groupId>org.powermock</groupId>
112                     <artifactId>powermock-module-junit4</artifactId>
113                 </exclusion>
114             </exclusions>
115         </dependency>
116     </dependencies>
117
118     <build>
119         <finalName>WSSimulator-${project.version}</finalName>
120         <plugins>
121             <plugin>
122                 <groupId>com.github.sylvainlaurent.maven</groupId>
123                 <artifactId>yaml-json-validator-maven-plugin</artifactId>
124                 <executions>
125                     <execution>
126                         <id>validate</id>
127                         <phase>validate</phase>
128                         <goals>
129                             <goal>validate</goal>
130                         </goals>
131                         <configuration>
132                             <validationSets>
133                                 <validationSet>
134                                     <includes>
135                                         <include>src/main/resources/**/*.y*ml</include>
136                                         <include>src/test/resources/**/*.y*ml</include>
137                                     </includes>
138                                 </validationSet>
139                                 <validationSet>
140                                     <includes>
141                                         <include>src/main/resources/**/*.json</include>
142                                         <include>src/test/resources/**/*.json</include>
143                                     </includes>
144                                 </validationSet>
145                             </validationSets>
146                             <skip>${skipYamlJsonValidator}</skip>
147                         </configuration>
148                     </execution>
149                 </executions>
150             </plugin>
151         </plugins>
152     </build>
153
154     <repositories>
155         <!-- LF repositories -->
156         <repository>
157             <id>ecomp-releases</id>
158             <name>Release Repository</name>
159             <url>${nexus.proxy}/content/repositories/releases/</url>
160         </repository>
161         <repository>
162             <id>ecomp-snapshots</id>
163             <name>Snapshots Repository</name>
164             <url>${nexus.proxy}/content/repositories/snapshots/</url>
165         </repository>
166         <repository>
167             <id>ecomp-public</id>
168             <name>Public Repository</name>
169             <url>${nexus.proxy}/content/repositories/public/</url>
170         </repository>
171         <!-- LF repositories END-->
172     </repositories>
173
174     <profiles>
175         <profile>
176             <id>docker</id>
177             <activation>
178                 <activeByDefault>false</activeByDefault>
179             </activation>
180             <build>
181                 <plugins>
182
183                     <plugin>
184                         <artifactId>maven-clean-plugin</artifactId>
185                         <version>3.0.0</version>
186                         <executions>
187                             <execution>
188                                 <id>clean-static-files</id>
189                                 <phase>clean</phase>
190                                 <goals>
191                                     <goal>clean</goal>
192                                 </goals>
193                                 <configuration>
194                                     <filesets>
195                                         <fileset>
196                                             <directory>${project.basedir}/sdc-simulator</directory>
197                                             <includes>
198                                                 <include>*.war</include>
199                                             </includes>
200                                             <followSymlinks>false</followSymlinks>
201                                         </fileset>
202                                     </filesets>
203                                 </configuration>
204                             </execution>
205                         </executions>
206                     </plugin>
207
208                     <plugin>
209                         <artifactId>maven-resources-plugin</artifactId>
210                         <executions>
211                             <execution>
212                                 <id>copy-resources-simulator</id>
213                                 <phase>verify</phase>
214                                 <goals>
215                                     <goal>copy-resources</goal>
216                                 </goals>
217                                 <configuration>
218                                     <outputDirectory>${project.basedir}/sdc-simulator
219                                     </outputDirectory>
220                                     <resources>
221                                         <resource>
222                                             <directory>${project.basedir}/target</directory>
223                                             <includes>
224                                                 <include>WSSimulator*.war</include>
225                                             </includes>
226                                         </resource>
227                                     </resources>
228                                 </configuration>
229                             </execution>
230                         </executions>
231                     </plugin>
232
233
234                     <plugin>
235                         <groupId>io.fabric8</groupId>
236                         <artifactId>docker-maven-plugin</artifactId>
237                         <configuration>
238                             <verbose>${verbose}</verbose>
239                             <apiVersion>${docker.api.version}</apiVersion>
240                             <registry>${docker.registry}</registry>
241                             <authConfig>
242                                 <pull>
243                                     <username>${docker.username}</username>
244                                     <password>${docker.password}</password>
245                                 </pull>
246                             </authConfig>
247                             <images>
248                                 <!-- Build simulator image -->
249                                 <image>
250                                     <name>${docker.namespace}/sdc-simulator</name>
251                                     <alias>sdc-simulator</alias>
252                                     <build>
253                                         <cleanup>try</cleanup>
254                                         <dockerFileDir>${basedir}${file.separator}sdc-simulator
255                                         </dockerFileDir>
256                                         <tags>
257                                             <tag>latest</tag>
258                                             <tag>
259                                                 ${parsedVersion.majorVersion}.${parsedVersion.minorVersion}-STAGING-latest
260                                             </tag>
261                                             <tag>
262                                                 ${parsedVersion.majorVersion}.${parsedVersion.minorVersion}-${maven.build.timestamp}
263                                             </tag>
264                                         </tags>
265                                     </build>
266                                 </image>
267                             </images>
268                         </configuration>
269                         <executions>
270                             <execution>
271                                 <id>clean-images</id>
272                                 <phase>pre-clean</phase>
273                                 <goals>
274                                     <goal>remove</goal>
275                                 </goals>
276                             </execution>
277                             <execution>
278                                 <id>generate-images</id>
279                                 <phase>install</phase>
280                                 <goals>
281                                     <goal>build</goal>
282                                 </goals>
283                             </execution>
284                             <execution>
285                                 <id>push-images</id>
286                                 <phase>deploy</phase>
287                                 <goals>
288                                     <goal>push</goal>
289                                 </goals>
290                             </execution>
291                         </executions>
292                     </plugin>
293                 </plugins>
294             </build>
295         </profile>
296     </profiles>
297 </project>