Fix pom.xml file
[sdc/dcae-d/dt-be-main.git] / pom.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <project 
3     xmlns="http://maven.apache.org/POM/4.0.0" 
4     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">
5     <modelVersion>4.0.0</modelVersion>
6     <groupId>org.onap.sdc.dcae</groupId>
7     <artifactId>dcae_dt_be_main</artifactId>
8     <version>1806.0.1-SNAPSHOT</version>
9     <packaging>pom</packaging>
10
11     <parent>
12         <groupId>org.springframework.boot</groupId>
13         <artifactId>spring-boot-starter-parent</artifactId>
14         <version>1.5.9.RELEASE</version>
15         <relativePath/>
16         <!-- lookup parent from repository -->
17     </parent>
18
19     <dependencies>
20         <dependency>
21             <groupId>org.onap.sdc.dcae.property</groupId>
22             <artifactId>DCAE-DT-PROPERTY</artifactId>
23             <version>${project.version}</version>
24             <exclusions>
25                 <exclusion>
26                     <groupId>org.slf4j</groupId>
27                     <artifactId>slf4j-api</artifactId>
28                 </exclusion>
29                 <exclusion>
30                     <groupId>log4j</groupId>
31                     <artifactId>log4j</artifactId>
32                 </exclusion>
33             </exclusions>
34         </dependency>
35     </dependencies>
36
37     <properties>
38         <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
39         <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
40         <java.version>1.8</java.version>
41         <nexus.proxy>https://nexus.onap.org</nexus.proxy>
42     </properties>
43     <build>
44         <plugins>
45             <plugin>
46                 <groupId>org.jacoco</groupId>
47                 <artifactId>jacoco-maven-plugin</artifactId>
48                 <version>0.7.9</version>
49                 <executions>
50                     <execution>
51                         <id>default-prepare-agent</id>
52                         <goals>
53                             <goal>prepare-agent</goal>
54                         </goals>
55                     </execution>
56                     <execution>
57                         <id>default-report</id>
58                         <goals>
59                             <goal>report</goal>
60                         </goals>
61                     </execution>
62                 </executions>
63             </plugin>
64         </plugins>
65     </build>
66     <profiles>
67         <profile>
68             <id>all</id>
69             <activation>
70                 <activeByDefault>true</activeByDefault>
71             </activation>
72             <modules>
73                 <module>dcaedt_validator</module>
74                 <module>dcaedt_catalog</module>
75                 <module>dcaedt_be</module>
76                 <module>dcaedt_tools</module>
77             </modules>
78         </profile>
79         <profile>
80             <id>docker</id>
81             <properties>
82                 <!-- Docker tags -->
83                 <maven.build.timestamp.format>yyyyMMdd'T'HHmm</maven.build.timestamp.format>
84                 <docker.tag>${project.version}-${maven.build.timestamp}</docker.tag>
85                 <docker.latest.tag>${project.version}-latest</docker.latest.tag>
86                 <docker.staging.tag>${parsedVersion.majorVersion}.${parsedVersion.minorVersion}-STAGING-latest</docker.staging.tag>
87             </properties>
88             <activation>
89                 <activeByDefault>false</activeByDefault>
90             </activation>
91             <build>
92                 <plugins>
93                     <plugin>
94                         <groupId>org.codehaus.mojo</groupId>
95                         <artifactId>build-helper-maven-plugin</artifactId>
96                         <version>1.8</version>
97                         <executions>
98                             <execution>
99                                 <id>parse-version</id>
100                                 <goals>
101                                     <goal>parse-version</goal>
102                                 </goals>
103                             </execution>
104                         </executions>
105                     </plugin>
106                     <plugin>
107                         <artifactId>maven-resources-plugin</artifactId>
108                         <version>3.0.2</version>
109                         <executions>
110                             <execution>
111                                 <id>copy-dcae-be-war</id>
112                                 <phase>validate</phase>
113                                 <goals>
114                                     <goal>copy-resources</goal>
115                                 </goals>
116                                 <configuration>
117                                     <outputDirectory>${project.basedir}/docker/docker_be/target</outputDirectory>
118                                     <resources>
119                                         <resource>
120                                             <directory>${project.basedir}/dcaedt_be/target</directory>
121                                             <includes>
122                                                 <include>dcae.war</include>
123                                             </includes>
124                                         </resource>
125                                     </resources>
126                                 </configuration>
127                             </execution>
128                             <execution>
129                                 <id>copy-dcae-tools-jar</id>
130                                 <phase>validate</phase>
131                                 <goals>
132                                     <goal>copy-resources</goal>
133                                 </goals>
134                                 <configuration>
135                                     <outputDirectory>${project.basedir}/docker/docker_tools/target</outputDirectory>
136                                     <resources>
137                                         <resource>
138                                             <directory>${project.basedir}/dcaedt_tools/target</directory>
139                                             <includes>
140                                                 <include>dcaedt_tools-${project.version}-jar-with-dependencies.jar</include>
141                                             </includes>
142                                         </resource>
143                                     </resources>
144                                 </configuration>
145                             </execution>
146                             <execution>
147                                 <id>copy-dcae-config-json</id>
148                                 <phase>validate</phase>
149                                 <goals>
150                                     <goal>copy-resources</goal>
151                                 </goals>
152                                 <configuration>
153                                     <outputDirectory>${project.basedir}/docker/docker_tools/chef-solo/cookbooks/Deploy-DCAE/files/default</outputDirectory>
154                                     <resources>
155                                         <resource>
156                                             <directory>${project.basedir}/dcaedt_tools/src/main/resources/conf</directory>
157                                             <includes>
158                                                 <include>config.json</include>
159                                             </includes>
160                                         </resource>
161                                     </resources>
162                                 </configuration>
163                             </execution>
164
165                         </executions>
166                     </plugin>
167                     <plugin>
168                         <groupId>io.fabric8</groupId>
169                         <artifactId>docker-maven-plugin</artifactId>
170                         <version>0.23.0</version>
171                         <configuration>
172                             <verbose>true</verbose>
173                             <apiVersion>1.23</apiVersion>
174                             <images>
175                                 <!-- Build backend image -->
176                                 <image>
177                                     <name>onap/dcae-be</name>
178                                     <alias>dcae-be</alias>
179                                     <build>
180                                         <cleanup>try</cleanup>
181                                         <dockerFileDir>${project.basedir}/docker/docker_be</dockerFileDir>
182                                         <tags>
183                                             <tag>${docker.tag}</tag>
184                                             <tag>${docker.latest.tag}</tag>
185                                             <tag>${docker.staging.tag}</tag>
186                                          </tags>
187                                     </build>
188                                 </image>
189                                 
190                                 <!-- Build tools image -->
191                                 <image>
192                                     <name>onap/dcae-tools</name>
193                                     <alias>dcae-tools</alias>
194                                     <build>
195                                         <cleanup>try</cleanup>
196                                         <dockerFileDir>${project.basedir}/docker/docker_tools</dockerFileDir>
197                                         <tags>
198                                             <tag>${docker.tag}</tag>
199                                             <tag>${docker.latest.tag}</tag>
200                                             <tag>${docker.staging.tag}</tag>
201                                          </tags>
202                                     </build>
203                                 </image>
204                             </images>
205                         </configuration>
206                         <executions>
207                             <execution>
208                                 <id>clean-images</id>
209                                 <phase>pre-clean</phase>
210                                 <goals>
211                                     <goal>remove</goal>
212                                 </goals>
213                                 <configuration>
214                                     <removeAll>true</removeAll>
215                                     <image>onap/dcae-be</image>
216                                 </configuration>
217                             </execution>
218                             <execution>
219                                 <id>generate-images</id>
220                                 <phase>package</phase>
221                                 <goals>
222                                     <goal>build</goal>
223                                 </goals>
224                             </execution>
225                             <execution>
226                                 <id>push-images</id>
227                                 <phase>deploy</phase>
228                                 <goals>
229                                     <goal>push</goal>
230                                 </goals>
231                                 <configuration>
232                                     <image>onap/dcae-be,onap/dcae-tools</image>
233                                 </configuration>
234                             </execution>
235                         </executions>
236                     </plugin>
237                 </plugins>
238             </build>
239          </profile>
240     </profiles>
241     <repositories>
242         <!-- LF repositories -->
243         <repository>
244             <id>ecomp-releases</id>
245             <name>Release Repository</name>
246             <url>${nexus.proxy}/content/repositories/releases/</url>
247         </repository>
248         <repository>
249             <id>ecomp-snapshots</id>
250             <name>Snapshots Repository</name>
251             <url>${nexus.proxy}/content/repositories/snapshots/</url>
252         </repository>
253         <repository>
254             <id>ecomp-public</id>
255             <name>Public Repository</name>
256             <url>${nexus.proxy}/content/repositories/public/</url>
257         </repository>
258         <!-- LF repositories END-->
259     </repositories>
260
261     <distributionManagement>
262         <repository>
263             <id>ecomp-releases</id>
264             <name>Release Repository</name>
265             <url>${nexus.proxy}/content/repositories/releases/</url>
266         </repository>
267         <snapshotRepository>
268             <id>ecomp-snapshots</id>
269             <name>Snapshot Repository</name>
270             <url>${nexus.proxy}/content/repositories/snapshots/</url>
271         </snapshotRepository>
272         <site>
273             <id>ecomp-site</id>
274             <url>dav:${nexus.proxy}${sitePath}</url>
275         </site>
276     </distributionManagement>
277 </project>
278