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/maven-v4_0_0.xsd">
5 <groupId>org.onap.ccsdk.parent</groupId>
6 <artifactId>odlparent-lite</artifactId>
7 <version>1.2.1-SNAPSHOT</version>
10 <modelVersion>4.0.0</modelVersion>
11 <packaging>pom</packaging>
12 <groupId>org.onap.sdnc.oam</groupId>
13 <artifactId>installation-sdnc</artifactId>
14 <version>1.5.0-SNAPSHOT</version>
16 <name>sdnc-oam :: installation :: ${project.artifactId}</name>
17 <description>Creates SDN Controller Docker container</description>
20 <image.name>onap/sdnc-image</image.name>
21 <sdnc.project.version>${project.version}</sdnc.project.version>
22 <sdnc.northbound.version>1.5.0-SNAPSHOT</sdnc.northbound.version>
23 <ccsdk.docker.version>0.4-STAGING-latest</ccsdk.docker.version>
24 <docker.buildArg.https_proxy>${https_proxy}</docker.buildArg.https_proxy>
25 <docker.push.phase>deploy</docker.push.phase>
26 <docker.verbose>true</docker.verbose>
27 <maven.build.timestamp.format>yyyyMMdd'T'HHmmss'Z'</maven.build.timestamp.format>
32 <groupId>org.onap.sdnc.northbound</groupId>
33 <artifactId>generic-resource-api-installer</artifactId>
34 <version>${sdnc.northbound.version}</version>
35 <classifier>repo</classifier>
39 <groupId>org.onap.sdnc.northbound</groupId>
40 <artifactId>vnfapi-installer</artifactId>
41 <version>${sdnc.northbound.version}</version>
42 <classifier>repo</classifier>
46 <groupId>org.onap.sdnc.northbound</groupId>
47 <artifactId>vnftools-installer</artifactId>
48 <version>${sdnc.northbound.version}</version>
49 <classifier>repo</classifier>
53 <groupId>org.onap.sdnc.northbound</groupId>
54 <artifactId>sdnc-northbound-features-installer</artifactId>
55 <version>${sdnc.northbound.version}</version>
56 <classifier>repo</classifier>
66 <groupId>org.codehaus.groovy.maven</groupId>
67 <artifactId>gmaven-plugin</artifactId>
70 <phase>validate</phase>
76 println project.properties['sdnc.project.version'];
78 if ( project.properties['sdnc.project.version'] != null ) {
79 versionArray = project.properties['sdnc.project.version'].split('\\.');
82 if (project.properties['sdnc.project.version'].endsWith("-SNAPSHOT")) {
83 project.properties['project.docker.latesttag.version']=versionArray[0] + '.' + versionArray[1] + "-STAGING-latest";
85 project.properties['project.docker.latesttag.version']=versionArray[0] + '.' + versionArray[1] + "-STAGING-latest";
88 println 'New Tag for docker:' + project.properties['project.docker.latesttag.version'];
96 <groupId>io.fabric8</groupId>
97 <artifactId>docker-maven-plugin</artifactId>
98 <version>0.16.5</version>
99 <inherited>false</inherited>
103 <name>${image.name}</name>
105 <cleanup>try</cleanup>
106 <dockerFileDir>${basedir}/target/docker-stage</dockerFileDir>
107 <dockerFile>${basedir}/target/docker-stage/Dockerfile</dockerFile>
109 <tag>${project.version}</tag>
110 <tag>${project.version}-STAGING-${maven.build.timestamp}</tag>
111 <tag>${project.docker.latesttag.version}</tag>
119 <id>generate-images</id>
120 <phase>package</phase>
128 <phase>${docker.push.phase}</phase>
140 <artifactId>maven-resources-plugin</artifactId>
141 <version>2.6</version>
144 <id>copy-dockerfile</id>
146 <goal>copy-resources</goal>
147 </goals><!-- here the phase you need -->
148 <phase>validate</phase>
150 <outputDirectory>${basedir}/target/docker-stage</outputDirectory>
153 <directory>src/main/docker</directory>
155 <include>Dockerfile</include>
157 <filtering>true</filtering>
164 <id>copy-scripts</id>
166 <goal>copy-resources</goal>
167 </goals><!-- here the phase you need -->
168 <phase>validate</phase>
170 <outputDirectory>${basedir}/target/docker-stage/opt/onap/sdnc/bin</outputDirectory>
173 <directory>src/main/scripts</directory>
175 <include>*.sh</include>
177 <filtering>false</filtering>
184 <id>copy-tarballs</id>
186 <goal>copy-resources</goal>
187 </goals><!-- here the phase you need -->
188 <phase>validate</phase>
190 <outputDirectory>${basedir}/target/docker-stage</outputDirectory>
193 <directory>src/main/resources</directory>
195 <include>idmlight.db.mv.db</include>
196 <include>AAF_RootCA.cer</include>
197 <include>truststoreONAPall.jks</include>
199 <filtering>false</filtering>
207 <goal>copy-resources</goal>
208 </goals><!-- here the phase you need -->
209 <phase>validate</phase>
211 <outputDirectory>${basedir}/target/docker-stage/opt/onap/sdnc/data</outputDirectory>
214 <directory>src/main/resources</directory>
216 <include>*.dump</include>
218 <filtering>false</filtering>
224 <id>copy-properties</id>
226 <goal>copy-resources</goal>
227 </goals><!-- here the phase you need -->
228 <phase>validate</phase>
230 <outputDirectory>${basedir}/target/docker-stage/opt/onap/sdnc/data/properties</outputDirectory>
233 <directory>../src/main/properties</directory>
235 <include>*.properties</include>
237 <filtering>false</filtering>
243 <id>copy-keystores</id>
245 <goal>copy-resources</goal>
246 </goals><!-- here the phase you need -->
247 <phase>validate</phase>
249 <outputDirectory>${basedir}/target/docker-stage/opt/onap/sdnc/data/stores</outputDirectory>
252 <directory>../src/main/stores</directory>
254 <include>*.jks</include>
256 <filtering>false</filtering>
264 <groupId>org.apache.maven.plugins</groupId>
265 <artifactId>maven-dependency-plugin</artifactId>
266 <version>3.0.2</version>
269 <id>unpack sdnc features</id>
270 <phase>generate-sources</phase>
272 <goal>unpack-dependencies</goal>
275 <outputDirectory>${basedir}/target/docker-stage</outputDirectory>
276 <excludeTransitive>true</excludeTransitive>
281 <phase>generate-sources</phase>
286 <outputDirectory>${basedir}/target/docker-stage/opt/onap/sdnc</outputDirectory>
289 <groupId>${project.groupId}</groupId>
290 <artifactId>platform-logic-installer</artifactId>
291 <version>${project.version}</version>
300 <artifactId>exec-maven-plugin</artifactId>
301 <groupId>org.codehaus.mojo</groupId>
302 <version>1.5.0</version>
306 <id>change shell permissions</id>
307 <phase>process-sources</phase>
312 <executable>/usr/bin/find</executable>
314 <argument>${basedir}/target/docker-stage/opt/onap/sdnc</argument>
315 <argument>-name</argument>
316 <argument>*.sh</argument>
317 <argument>-exec</argument>
318 <argument>chmod</argument>
319 <argument>+x</argument>
320 <argument>{}</argument>
321 <argument>;</argument>