blob: b4445dd04581463050bb67ebb6f36c66ae5c5c6d [file] [log] [blame]
Sonsino, Ofir (os0695)ff76b5e2018-07-10 15:57:37 +03001<?xml version="1.0"?>
2<project
3 xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
4 xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
5 <modelVersion>4.0.0</modelVersion>
6
7 <!-- This is the Maven project object model (POM) file for VID web application
8 based on the ECOMP SDK distribution. This file stands alone; it does not
9 inherit from a parent maven module. -->
10 <groupId>org.onap.vid</groupId>
11 <artifactId>vid-webpack-master</artifactId>
Sonsino, Ofir (os0695)09e4dff2018-08-15 15:39:55 +030012 <version>1.3.0-SNAPSHOT</version>
Sonsino, Ofir (os0695)ff76b5e2018-07-10 15:57:37 +030013 <packaging>war</packaging>
14 <name>VID UI</name>
15 <description>VID UI</description>
16
17 <properties>
18 <encoding>UTF-8</encoding>
Sonsino, Ofir (os0695)ff76b5e2018-07-10 15:57:37 +030019 <!-- Skip assembling the zip by default -->
20 <skipassembly>true</skipassembly>
21 <!-- Tests usually require some setup that maven cannot do, so skip. -->
22 <skiptests>false</skiptests>
23 <!-- this should be commented for local debugging -->
24 <!-- <deployenv>local</deployenv> -->
25 <nexusproxy>https://nexus.onap.org</nexusproxy>
26 <stagingNexusPath>content/repositories/staging/</stagingNexusPath>
27 <snapshotNexusPath>content/repositories/snapshots/</snapshotNexusPath>
28 <releaseNexusPath>content/repositories/releases/</releaseNexusPath>
29 </properties>
30
31
32 <repositories>
33 <repository>
Sonsino, Ofir (os0695)ff76b5e2018-07-10 15:57:37 +030034 <id>onap-staging</id>
35 <name>ONAP - Staging Repository</name>
36 <url>${nexusproxy}/${stagingNexusPath}</url>
37 </repository>
38 <repository>
Sonsino, Ofir (os0695)ff76b5e2018-07-10 15:57:37 +030039 <id>ecomp-releases</id>
40 <name>OpenECOMP - Release Repository</name>
41 <url>${nexusproxy}/${releaseNexusPath}</url>
42 </repository>
43 <repository>
44 <id>ecomp-snapshots</id>
45 <name>OpenECOMP - Snapshot Repository</name>
46 <url>${nexusproxy}/${snapshotNexusPath}</url>
47 </repository>
48 <repository>
49 <id>ecomp-public</id>
50 <name>ecomp onap public Repository</name>
51 <url>https://nexus.onap.org/content/groups/public</url>
52 </repository>
53 </repositories>
54
Sonsino, Ofir (os0695)ccfb3ba2018-08-12 17:16:13 +030055 <distributionManagement>
biniek6f2b2082018-12-17 11:18:05 +010056 <repository>
57 <id>ecomp-releases</id>
58 <name>VID Release Repository</name>
59 <url>${nexusproxy}/${releaseNexusPath}</url>
60 </repository>
61 <snapshotRepository>
62 <id>ecomp-snapshots</id>
63 <name>VID Snapshot Repository</name>
64 <url>${nexusproxy}/${snapshotNexusPath}</url>
65 </snapshotRepository>
Sonsino, Ofir (os0695)ccfb3ba2018-08-12 17:16:13 +030066
67 </distributionManagement>
68
Sonsino, Ofir (os0695)ff76b5e2018-07-10 15:57:37 +030069 <profiles>
70 <profile>
71 <id>if-not-webpack</id>
biniek6f2b2082018-12-17 11:18:05 +010072 <activation>
73 <activeByDefault>true</activeByDefault>
74 </activation>
Sonsino, Ofir (os0695)ff76b5e2018-07-10 15:57:37 +030075 <build>
76 <plugins>
77 <plugin>
78 <groupId>org.apache.maven.plugins</groupId>
79 <artifactId>maven-antrun-plugin</artifactId>
80 <version>1.8</version>
81 <executions>
82 <execution>
83 <id>make-empty-dist</id>
84 <phase>validate</phase>
85 <configuration>
86 <target>
biniek6f2b2082018-12-17 11:18:05 +010087 <mkdir dir="${project.basedir}/dist/"/>
Sonsino, Ofir (os0695)ff76b5e2018-07-10 15:57:37 +030088 <echo file="${project.basedir}/dist/NO-WEBPACK.txt" append="false">
biniek6f2b2082018-12-17 11:18:05 +010089 Note: 'webpack' profile was not selected while mvn build. This 'dist' folder was created to make
90 the war creation through.
Sonsino, Ofir (os0695)ff76b5e2018-07-10 15:57:37 +030091 </echo>
92 </target>
93 </configuration>
94 <goals>
95 <goal>run</goal>
96 </goals>
97 </execution>
98 </executions>
99 </plugin>
100
101 </plugins>
102 </build>
103 </profile>
104 <profile>
105 <id>webpack</id>
106 <build>
107 <plugins>
108 <plugin>
109 <groupId>com.github.eirslett</groupId>
110 <artifactId>frontend-maven-plugin</artifactId>
111 <!-- NB! Set <version> to the latest released version of frontend-maven-plugin, like in README.md -->
112 <version>1.6</version>
113
114 <executions>
115
116 <execution>
117 <id>install node and npm</id>
118 <goals>
119 <goal>install-node-and-npm</goal>
120 </goals>
121 <configuration>
122 <!-- See https://nodejs.org/en/download/ for latest node and npm (lts) versions -->
123 <nodeVersion>v8.9.4</nodeVersion>
124 <npmVersion>5.6.0</npmVersion>
125 </configuration>
126 </execution>
127
128 <execution>
129 <id>npm set no-progress</id>
130 <goals>
131 <goal>npm</goal>
132 </goals>
133 <configuration>
134 <arguments>set progress=false</arguments>
135 </configuration>
136 </execution>
137
138 <execution>
139 <id>npm install</id>
140 <goals>
141 <goal>npm</goal>
142 </goals>
143 <!-- Optional configuration which provides for running any npm command -->
144 <configuration>
145 <arguments>install</arguments>
146 <environmentVariables>
147 <CYPRESS_INSTALL_BINARY>0</CYPRESS_INSTALL_BINARY>
Sonsino, Ofir (os0695)ff76b5e2018-07-10 15:57:37 +0300148 </environmentVariables>
149 </configuration>
150 </execution>
151
152 <execution>
153 <id>npm run test</id>
154 <goals>
155 <goal>npm</goal>
156 </goals>
157 <configuration>
158 <arguments>run test</arguments>
159 </configuration>
160 </execution>
161
162 <execution>
163 <id>npm run build</id>
164 <goals>
165 <goal>npm</goal>
166 </goals>
167 <configuration>
168 <arguments>run build</arguments>
169 </configuration>
170 </execution>
171
172 </executions>
173 </plugin>
174 </plugins>
175 </build>
176 </profile>
177
178 <profile>
179 <id>cypress</id>
180 <build>
181 <plugins>
182 <plugin>
183 <groupId>com.github.eirslett</groupId>
184 <artifactId>frontend-maven-plugin</artifactId>
185 <!-- NB! Set <version> to the latest released version of frontend-maven-plugin, like in README.md -->
186 <version>1.6</version>
187
188 <executions>
189
190 <execution>
191 <id>install node and npm</id>
192 <goals>
193 <goal>install-node-and-npm</goal>
194 </goals>
195 <configuration>
196 <!-- See https://nodejs.org/en/download/ for latest node and npm (lts) versions -->
197 <nodeVersion>v8.9.4</nodeVersion>
198 <npmVersion>5.6.0</npmVersion>
199 </configuration>
200 </execution>
201
202 <execution>
203 <id>npm install cypress</id>
204 <goals>
205 <goal>npm</goal>
206 </goals>
207 <!-- Optional configuration which provides for running any npm command -->
208 <configuration>
209 <arguments>install --verbose cypress @bahmutov/add-typescript-to-cypress</arguments>
210 <environmentVariables>
211 <NO_PROXY>.att.com</NO_PROXY>
212 <http_proxy>http://one.proxy.att.com:8080</http_proxy>
213 <https_proxy>http://one.proxy.att.com:8080</https_proxy>
214 </environmentVariables>
215 </configuration>
216 </execution>
217
218 <execution>
219 <id>npm run cypress</id>
220 <goals>
221 <goal>npm</goal>
222 </goals>
223 <configuration>
224 <npmInheritsProxyConfigFromMaven>false</npmInheritsProxyConfigFromMaven>
225 <arguments>run cypress:run -- --config baseUrl=http://${VID_HOST}:8080/vid</arguments>
226 </configuration>
227 </execution>
228
229 </executions>
230 </plugin>
231 </plugins>
232 </build>
233 </profile>
234 </profiles>
235
236 <build>
237 <finalName>vid-webpack-master</finalName>
238 <plugins>
239
240 <plugin>
241 <groupId>org.apache.maven.plugins</groupId>
242 <artifactId>maven-war-plugin</artifactId>
243 <version>3.2.0</version>
244 <configuration>
245 <webResources>
246 <resource>
247 <!-- this is relative to the pom.xml directory -->
248 <directory>dist</directory>
249 <targetPath>app/ui</targetPath>
250 </resource>
251 </webResources>
252 <webXml>src/WEB-INF/web.xml</webXml>
253 </configuration>
254 </plugin>
255
256 </plugins>
Sonsino, Ofir (os0695)ff76b5e2018-07-10 15:57:37 +0300257 </build>
Sonsino, Ofir (os0695)ff76b5e2018-07-10 15:57:37 +0300258 <dependencies>
259 </dependencies>
Sonsino, Ofir (os0695)ff76b5e2018-07-10 15:57:37 +0300260</project>