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"
3 xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
6 <groupId>org.onap.sdnc.oam</groupId>
7 <artifactId>installation</artifactId>
8 <version>1.2.1-SNAPSHOT</version>
11 <modelVersion>4.0.0</modelVersion>
12 <packaging>pom</packaging>
13 <groupId>org.onap.sdnc.oam</groupId>
14 <artifactId>installation-sdnc</artifactId>
15 <version>1.2.1-SNAPSHOT</version>
17 <name>Installation - sdnc</name>
18 <description>Creates SDN Controller Docker container</description>
21 <image.name>onap/sdnc-image</image.name>
22 <sdnc.project.version>${project.version}</sdnc.project.version>
23 <sdnc.northbound.version>${project.version}</sdnc.northbound.version>
24 <docker.buildArg.https_proxy>${https_proxy}</docker.buildArg.https_proxy>
33 <groupId>org.codehaus.groovy.maven</groupId>
34 <artifactId>gmaven-plugin</artifactId>
37 <phase>validate</phase>
43 println project.properties['sdnc.project.version'];
45 if ( project.properties['sdnc.project.version'] != null ) {
47 project.properties['sdnc.project.version'].split('\\.');
50 if (project.properties['sdnc.project.version'].endsWith("-SNAPSHOT")) {
51 project.properties['project.docker.latesttag.version']=versionArray[0] + '.' + versionArray[1] + "-STAGING-latest";
53 project.properties['project.docker.latesttag.version']=versionArray[0] + '.' + versionArray[1] + "-STAGING-latest";
56 println 'New Tag for docker:' +
57 project.properties['project.docker.latesttag.version'];
65 <groupId>io.fabric8</groupId>
66 <artifactId>docker-maven-plugin</artifactId>
67 <version>0.16.5</version>
68 <inherited>false</inherited>
72 <name>${image.name}</name>
74 <cleanup>try</cleanup>
75 <dockerFileDir>${basedir}/target/docker-stage</dockerFileDir>
76 <dockerFile>${basedir}/target/docker-stage/Dockerfile</dockerFile>
78 <tag>${project.version}</tag>
79 <tag>${project.version}-STAGING-${maven.build.timestamp}</tag>
80 <tag>${project.docker.latesttag.version}</tag>
88 <id>generate-images</id>
89 <phase>package</phase>
109 <artifactId>maven-resources-plugin</artifactId>
110 <version>2.6</version>
113 <id>copy-dockerfile</id>
115 <goal>copy-resources</goal>
116 </goals><!-- here the phase you need -->
117 <phase>validate</phase>
119 <outputDirectory>${basedir}/target/docker-stage</outputDirectory>
122 <directory>src/main/docker</directory>
124 <include>Dockerfile</include>
126 <filtering>true</filtering>
133 <id>copy-scripts</id>
135 <goal>copy-resources</goal>
136 </goals><!-- here the phase you need -->
137 <phase>validate</phase>
139 <outputDirectory>${basedir}/target/docker-stage/opt/onap/sdnc/bin</outputDirectory>
142 <directory>src/main/scripts</directory>
144 <include>*.sh</include>
146 <filtering>false</filtering>
153 <id>copy-tarballs</id>
155 <goal>copy-resources</goal>
156 </goals><!-- here the phase you need -->
157 <phase>validate</phase>
159 <outputDirectory>${basedir}/target/docker-stage</outputDirectory>
162 <directory>src/main/resources</directory>
164 <include>idmlight.db.mv.db</include>
166 <filtering>false</filtering>
174 <goal>copy-resources</goal>
175 </goals><!-- here the phase you need -->
176 <phase>validate</phase>
178 <outputDirectory>${basedir}/target/docker-stage/opt/onap/sdnc/data</outputDirectory>
181 <directory>src/main/resources</directory>
183 <include>*.dump</include>
185 <filtering>false</filtering>
191 <id>copy-properties</id>
193 <goal>copy-resources</goal>
194 </goals><!-- here the phase you need -->
195 <phase>validate</phase>
197 <outputDirectory>${basedir}/target/docker-stage/opt/onap/sdnc/data/properties</outputDirectory>
200 <directory>../src/main/properties</directory>
202 <include>*.properties</include>
204 <filtering>false</filtering>
210 <id>copy-keystores</id>
212 <goal>copy-resources</goal>
213 </goals><!-- here the phase you need -->
214 <phase>validate</phase>
216 <outputDirectory>${basedir}/target/docker-stage/opt/onap/sdnc/data/stores</outputDirectory>
219 <directory>../src/main/stores</directory>
221 <include>*.jks</include>
223 <filtering>false</filtering>
231 <artifactId>exec-maven-plugin</artifactId>
232 <groupId>org.codehaus.mojo</groupId>
233 <version>1.5.0</version>
237 <id>Get features</id>
238 <phase>generate-sources</phase>
243 <executable>/bin/bash</executable>
244 <environmentVariables>
245 <SDNC_NORTHBOUND_VERSION>${sdnc.northbound.version}</SDNC_NORTHBOUND_VERSION>
246 <SDNC_OAM_VERSION>${project.version}</SDNC_OAM_VERSION>
247 </environmentVariables>
249 <argument>${basedir}/src/main/scripts/installZips.sh</argument>
250 <argument>${basedir}/target/docker-stage/opt/onap/sdnc</argument>
256 <id>change shell permissions</id>
257 <phase>process-sources</phase>
262 <executable>/usr/bin/find</executable>
264 <argument>${basedir}/target/docker-stage/opt/onap/sdnc</argument>
265 <argument>-name</argument>
266 <argument>*.sh</argument>
267 <argument>-exec</argument>
268 <argument>chmod</argument>
269 <argument>+x</argument>
270 <argument>{}</argument>
271 <argument>;</argument>
283 <name>openECOMP</name>