Fix Jenkins staging job
[nonrtric.git] / sdnc-a1-controller / oam / installation / sdnc / pom.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!--
3   ============LICENSE_START=======================================================
4    Modifications Copyright (C) 2019 Nordix Foundation.
5   ================================================================================
6   Licensed under the Apache License, Version 2.0 (the "License");
7   you may not use this file except in compliance with the License.
8   You may obtain a copy of the License at
9
10        http://www.apache.org/licenses/LICENSE-2.0
11
12   Unless required by applicable law or agreed to in writing, software
13   distributed under the License is distributed on an "AS IS" BASIS,
14   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15   See the License for the specific language governing permissions and
16   limitations under the License.
17
18   SPDX-License-Identifier: Apache-2.0
19   ============LICENSE_END=========================================================
20 -->
21 <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">
22
23         <repositories>
24                 <repository>
25                         <id>onap-releases</id>
26                         <name>onap-releases</name>
27                         <url>https://nexus.onap.org/content/repositories/releases/</url>
28                 </repository>
29         </repositories>
30
31     <parent>
32         <groupId>org.onap.ccsdk.parent</groupId>
33         <artifactId>odlparent-lite</artifactId>
34         <version>1.4.3</version>
35     </parent>
36
37     <modelVersion>4.0.0</modelVersion>
38     <packaging>pom</packaging>
39     <groupId>org.onap.sdnc.oam</groupId>
40     <artifactId>installation-sdnc</artifactId>
41     <version>1.7.3-SNAPSHOT</version>
42
43     <name>sdnc-oam :: installation :: ${project.artifactId}</name>
44     <description>Creates SDN Controller Docker container</description>
45
46     <properties>
47         <image.name>onap/sdnc-aaf-image</image.name>
48         <standalone.image.name>o-ran-sc/nonrtric-a1-controller</standalone.image.name>
49         <sdnc.project.version>${project.version}</sdnc.project.version>
50         <sdnc.build.timestamp>${maven.build.timestamp}</sdnc.build.timestamp>
51         <sdnc.northbound.version>1.7.3-SNAPSHOT</sdnc.northbound.version>
52         <ccsdk.docker.version>0.6.3</ccsdk.docker.version>
53         <ccsdk.features.version>0.6.3</ccsdk.features.version>
54         <sdnc.keystore>org.onap.sdnc.p12</sdnc.keystore>
55         <sdnc.keypass><![CDATA[ff^G9D]yf&r}Ktum@BJ0YB?N]]></sdnc.keypass>
56         <sdnc.secureport>8443</sdnc.secureport>
57         <docker.buildArg.https_proxy>${https_proxy}</docker.buildArg.https_proxy>
58         <docker.push.phase>deploy</docker.push.phase>
59         <docker.verbose>true</docker.verbose>
60         <maven.build.timestamp.format>yyyyMMdd'T'HHmmss'Z'</maven.build.timestamp.format>
61     </properties>
62
63     <dependencies>
64         <dependency>
65             <groupId>org.onap.sdnc.northbound</groupId>
66             <artifactId>nonrt-ric-api-installer</artifactId>
67             <version>${sdnc.northbound.version}</version>
68             <classifier>repo</classifier>
69             <type>zip</type>
70         </dependency>
71         <dependency>
72             <groupId>org.onap.sdnc.northbound</groupId>
73             <artifactId>sdnc-northbound-features-installer</artifactId>
74             <version>${sdnc.northbound.version}</version>
75             <classifier>repo</classifier>
76             <type>zip</type>
77         </dependency>
78         <dependency>
79             <groupId>org.onap.ccsdk.features.sdnr.northbound</groupId>
80             <artifactId>oofpcipoc-installer</artifactId>
81             <version>${ccsdk.features.version}</version>
82             <classifier>repo</classifier>
83             <type>zip</type>
84         </dependency>
85         <dependency>
86             <groupId>org.onap.ccsdk.features.sdnr.northbound</groupId>
87             <artifactId>sdnr-northbound-features-installer</artifactId>
88             <version>${ccsdk.features.version}</version>
89             <classifier>repo</classifier>
90             <type>zip</type>
91         </dependency>
92         <dependency>
93             <groupId>org.onap.ccsdk.features.sdnr.wt</groupId>
94             <artifactId>sdnr-wt-feature-aggregator-installer</artifactId>
95             <version>${ccsdk.features.version}</version>
96             <classifier>repo</classifier>
97             <type>zip</type>
98         </dependency>
99     </dependencies>
100
101     <build>
102         <plugins>
103
104
105             <plugin>
106                 <groupId>org.codehaus.groovy.maven</groupId>
107                 <artifactId>gmaven-plugin</artifactId>
108                 <executions>
109                     <execution>
110                         <phase>validate</phase>
111                         <goals>
112                             <goal>execute</goal>
113                         </goals>
114                         <configuration>
115                             <source>${basedir}/../TagVersion.groovy</source>
116                         </configuration>
117                     </execution>
118                 </executions>
119             </plugin>
120
121             <plugin>
122                 <groupId>io.fabric8</groupId>
123                 <artifactId>docker-maven-plugin</artifactId>
124                 <version>0.30.0</version>
125                 <inherited>false</inherited>
126                 <executions>
127                    <execution>
128                      <id>generate-standalone-images</id>
129                      <phase>package</phase>
130                      <goals>
131                       <goal>build</goal>
132                      </goals>
133                      <configuration>
134                       <images>
135                        <image>
136                         <name>${standalone.image.name}:${project.version}</name>
137                         <build>
138                          <cleanup>try</cleanup>
139                          <dockerFileDir>${basedir}/target/docker-stage</dockerFileDir>
140                          <dockerFile>standalone.Dockerfile</dockerFile>
141                          <tags>
142                              <tag>${project.version}</tag>
143                          </tags>
144                         </build>
145                        </image>
146                       </images>
147                      </configuration>
148                    </execution>
149                    <execution>
150                      <id>push-standalone-images</id>
151                      <phase>${docker.push.phase}</phase>
152                      <goals>
153                       <goal>build</goal>
154                       <goal>push</goal>
155                      </goals>
156                      <configuration>
157                        <pushRegistry>${env.CONTAINER_PUSH_REGISTRY}</pushRegistry>
158                        <images>
159                         <image>
160                          <name>${standalone.image.name}:${project.version}</name>
161                          <build>
162                           <cleanup>try</cleanup>
163                           <dockerFileDir>${basedir}/target/docker-stage</dockerFileDir>
164                           <dockerFile>standalone.Dockerfile</dockerFile>
165                           <tags>
166                              <tag>${project.version}</tag>
167                           </tags>
168                          </build>
169                         </image>
170                        </images>
171                      </configuration>
172                   </execution>
173                 </executions>
174             </plugin>
175             <plugin>
176                 <artifactId>maven-resources-plugin</artifactId>
177                 <version>2.6</version>
178                 <executions>
179                     <execution>
180                         <id>copy-dockerfile</id>
181                         <goals>
182                             <goal>copy-resources</goal>
183                         </goals><!-- here the phase you need -->
184                         <phase>validate</phase>
185                         <configuration>
186                             <outputDirectory>${basedir}/target/docker-stage</outputDirectory>
187                             <resources>
188                                 <resource>
189                                     <directory>src/main/docker</directory>
190                                     <includes>
191                                         <include>standalone.Dockerfile</include>
192                                     </includes>
193                                     <filtering>true</filtering>
194                                 </resource>
195                             </resources>
196                         </configuration>
197                     </execution>
198                     <execution>
199                         <id>copy-scripts</id>
200                         <goals>
201                             <goal>copy-resources</goal>
202                         </goals><!-- here the phase you need -->
203                         <phase>validate</phase>
204                         <configuration>
205                             <outputDirectory>${basedir}/target/docker-stage/opt/onap/sdnc/bin</outputDirectory>
206                             <resources>
207                                 <resource>
208                                     <directory>src/main/scripts</directory>
209                                     <includes>
210                                         <include>*.py</include>
211                                         <include>*.sh</include>
212                                     </includes>
213                                     <filtering>false</filtering>
214                                 </resource>
215                             </resources>
216                         </configuration>
217                     </execution>
218                     <execution>
219                         <id>copy-tarballs</id>
220                         <goals>
221                             <goal>copy-resources</goal>
222                         </goals><!-- here the phase you need -->
223                         <phase>validate</phase>
224                         <configuration>
225                             <outputDirectory>${basedir}/target/docker-stage</outputDirectory>
226                             <resources>
227                                 <resource>
228                                     <directory>src/main/resources</directory>
229                                     <includes>
230                                         <include>idmlight.db.mv.db</include>
231                                         <include>truststoreONAPall.jks</include>
232                                         <include>aaa-app-config.xml</include>
233                                     </includes>
234                                     <filtering>false</filtering>
235                                 </resource>
236                             </resources>
237                         </configuration>
238                     </execution>
239                     <execution>
240                         <id>copy-data</id>
241                         <goals>
242                             <goal>copy-resources</goal>
243                         </goals><!-- here the phase you need -->
244                         <phase>validate</phase>
245                         <configuration>
246                             <outputDirectory>${basedir}/target/docker-stage/opt/onap/sdnc/data</outputDirectory>
247                             <resources>
248                                 <resource>
249                                     <directory>src/main/resources</directory>
250                                     <includes>
251                                         <include>*.dump</include>
252                                     </includes>
253                                     <filtering>false</filtering>
254                                 </resource>
255                             </resources>
256                         </configuration>
257                     </execution>
258                     <execution>
259                         <id>copy-properties</id>
260                         <goals>
261                             <goal>copy-resources</goal>
262                         </goals><!-- here the phase you need -->
263                         <phase>validate</phase>
264                         <configuration>
265                             <outputDirectory>${basedir}/target/docker-stage/opt/onap/sdnc/data/properties</outputDirectory>
266                             <resources>
267                                 <resource>
268                                     <directory>../src/main/properties</directory>
269                                     <includes>
270                                         <include>*.properties</include>
271                                         <include>*.props</include>
272                                         <include>*.csv</include>
273                                     </includes>
274                                     <filtering>false</filtering>
275                                 </resource>
276                             </resources>
277                         </configuration>
278                     </execution>
279                     <execution>
280                         <id>copy-keystores</id>
281                         <goals>
282                             <goal>copy-resources</goal>
283                         </goals><!-- here the phase you need -->
284                         <phase>validate</phase>
285                         <configuration>
286                             <outputDirectory>${basedir}/target/docker-stage/opt/onap/sdnc/data/stores</outputDirectory>
287                             <resources>
288                                 <resource>
289                                     <directory>../src/main/stores</directory>
290                                     <includes>
291                                         <include>*.jks</include>
292                                         <include>*.keyfile</include>
293                                         <include>*.p12</include>
294                                     </includes>
295                                     <filtering>false</filtering>
296                                 </resource>
297                             </resources>
298                         </configuration>
299                     </execution>
300                 </executions>
301             </plugin>
302             <plugin>
303                 <groupId>org.apache.maven.plugins</groupId>
304                 <artifactId>maven-dependency-plugin</artifactId>
305                 <version>3.0.2</version>
306                 <executions>
307                     <execution>
308                         <id>unpack sdnc features</id>
309                         <phase>generate-sources</phase>
310                         <goals>
311                             <goal>unpack-dependencies</goal>
312                         </goals>
313                         <configuration>
314                             <outputDirectory>${basedir}/target/docker-stage</outputDirectory>
315                             <excludeTransitive>true</excludeTransitive>
316                         </configuration>
317                     </execution>
318                     <execution>
319                         <id>unpack dgs</id>
320                         <phase>generate-sources</phase>
321                         <goals>
322                             <goal>unpack</goal>
323                         </goals>
324                         <configuration>
325                             <outputDirectory>${basedir}/target/docker-stage/opt/onap/sdnc</outputDirectory>
326                             <artifactItems>
327                                 <artifactItem>
328                                     <groupId>${project.groupId}</groupId>
329                                     <artifactId>platform-logic-installer</artifactId>
330                                     <version>${project.version}</version>
331                                     <type>zip</type>
332                                 </artifactItem>
333                             </artifactItems>
334                         </configuration>
335                     </execution>
336                 </executions>
337             </plugin>
338             <plugin>
339                 <artifactId>exec-maven-plugin</artifactId>
340                 <groupId>org.codehaus.mojo</groupId>
341                 <version>1.5.0</version>
342                 <executions>
343                     <execution>
344                         <id>change shell permissions</id>
345                         <phase>process-sources</phase>
346                         <goals>
347                             <goal>exec</goal>
348                         </goals>
349                         <configuration>
350                             <executable>/usr/bin/find</executable>
351                             <arguments>
352                                 <argument>${basedir}/target/docker-stage/opt/onap/sdnc</argument>
353                                 <argument>-name</argument>
354                                 <argument>*.sh</argument>
355                                 <argument>-exec</argument>
356                                 <argument>chmod</argument>
357                                 <argument>+x</argument>
358                                 <argument>{}</argument>
359                                 <argument>;</argument>
360                             </arguments>
361                         </configuration>
362                     </execution>
363                 </executions>
364             </plugin>
365         </plugins>
366     </build>
367     <organization>
368         <name>ONAP</name>
369     </organization>
370 </project>