Release docker image of AAF to onap nexus
[aaf/authz.git] / authz-service / pom.xml
1 <?xml version="1.0" encoding="UTF-8"?>\r
2 <!--\r
3   ============LICENSE_START====================================================\r
4   * org.onap.aaf\r
5   * ===========================================================================\r
6   * Copyright © 2017 AT&T Intellectual Property. All rights reserved.\r
7   * ===========================================================================\r
8   * Licensed under the Apache License, Version 2.0 (the "License");\r
9   * you may not use this file except in compliance with the License.\r
10   * You may obtain a copy of the License at\r
11   * \r
12    *      http://www.apache.org/licenses/LICENSE-2.0\r
13   * \r
14    * Unless required by applicable law or agreed to in writing, software\r
15   * distributed under the License is distributed on an "AS IS" BASIS,\r
16   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
17   * See the License for the specific language governing permissions and\r
18   * limitations under the License.\r
19   * ============LICENSE_END====================================================\r
20   *\r
21   * ECOMP is a trademark and service mark of AT&T Intellectual Property.\r
22   *\r
23 -->\r
24 <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"\r
25         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">\r
26         <modelVersion>4.0.0</modelVersion>\r
27         <parent>\r
28                 <groupId>org.onap.aaf.authz</groupId>\r
29                 <artifactId>parent</artifactId>\r
30                 <version>1.0.0-SNAPSHOT</version>\r
31                 <relativePath>../pom.xml</relativePath>\r
32         </parent>\r
33                 \r
34         <artifactId>authz-service</artifactId>\r
35         <name>Authz Service</name>\r
36         <description>API for Authorization and Authentication</description>\r
37                 <url>https://github.com/att/AAF</url>\r
38         <licenses>\r
39                 <license>\r
40                 <name>BSD License</name>\r
41                 <url> </url>\r
42                 </license>\r
43         </licenses>\r
44         <developers>\r
45                 <developer>\r
46                 <name>Jonathan Gathman</name>\r
47                 <email></email>\r
48         <organization>ATT</organization>\r
49         <organizationUrl></organizationUrl>\r
50                 </developer>\r
51         </developers>\r
52 \r
53         <properties>\r
54                 <maven.test.failure.ignore>true</maven.test.failure.ignore>\r
55                 <project.swmVersion>1</project.swmVersion>\r
56                         <project.cadiVersion>1.0.0-SNAPSHOT</project.cadiVersion>\r
57             <dockerLocation>${basedir}/target/</dockerLocation>\r
58                 <docker.registry>nexus3.onap.org</docker.registry>\r
59                 <distFilesRootDirPath>opt/app/aaf/${project.artifactId}/${project.version}</distFilesRootDirPath>\r
60                         <sonar.language>java</sonar.language>\r
61                 <sonar.java.coveragePlugin>jacoco</sonar.java.coveragePlugin>\r
62                 <sonar.surefire.reportsPath>${project.build.directory}/surefire-reports</sonar.surefire.reportsPath>\r
63                 <sonar.jacoco.reportPath>${project.build.directory}/coverage-reports/jacoco.exec</sonar.jacoco.reportPath>\r
64                 <sonar.jacoco.itReportPath>${project.build.directory}/coverage-reports/jacoco-it.exec</sonar.jacoco.itReportPath>\r
65                 <sonar.jacoco.reportMissing.force.zero>true</sonar.jacoco.reportMissing.force.zero>\r
66                 <sonar.projectVersion>${project.version}</sonar.projectVersion>\r
67         <nexusproxy>https://nexus.onap.org</nexusproxy>\r
68                 <snapshotNexusPath>/content/repositories/snapshots/</snapshotNexusPath>\r
69                 <releaseNexusPath>/content/repositories/releases/</releaseNexusPath>\r
70                 <stagingNexusPath>/content/repositories/staging/</stagingNexusPath>\r
71                 <sitePath>/content/sites/site/${project.groupId}/${project.artifactId}/${project.version}</sitePath>\r
72         </properties>\r
73         \r
74                 \r
75         <dependencies>\r
76         <dependency>\r
77             <groupId>org.onap.aaf.authz</groupId>\r
78             <artifactId>authz-client</artifactId>\r
79         </dependency>\r
80                 \r
81                 <dependency>\r
82             <groupId>org.onap.aaf.authz</groupId>\r
83             <artifactId>authz-cmd</artifactId>\r
84         </dependency>           \r
85         <dependency>\r
86             <groupId>org.onap.aaf.authz</groupId>\r
87             <artifactId>authz-core</artifactId>\r
88             <exclusions>\r
89                           <exclusion> \r
90                                         <groupId>javax.servlet</groupId>\r
91                         <artifactId>servlet-api</artifactId>\r
92                    </exclusion>\r
93                     </exclusions> \r
94         </dependency>\r
95         \r
96         <dependency>\r
97             <groupId>org.onap.aaf.authz</groupId>\r
98             <artifactId>authz-cass</artifactId>\r
99         </dependency>\r
100 \r
101         <dependency>\r
102             <groupId>org.onap.aaf.authz</groupId>\r
103             <artifactId>authz-defOrg</artifactId>\r
104             <version>${project.version}</version>\r
105         </dependency>\r
106 \r
107 \r
108         \r
109         <dependency > \r
110                         <groupId>org.onap.aaf.inno</groupId>\r
111                         <artifactId>env</artifactId>\r
112                 </dependency>\r
113 \r
114 \r
115                 <dependency>\r
116                         <groupId>org.onap.aaf.cadi</groupId>\r
117                         <artifactId>cadi-core</artifactId>\r
118                 </dependency>\r
119 \r
120                 <dependency>\r
121                         <groupId>com.att.aft</groupId>\r
122                         <artifactId>dme2</artifactId>\r
123                 </dependency>\r
124 \r
125                 <dependency>\r
126                         <groupId>org.onap.aaf.inno</groupId>\r
127                         <artifactId>rosetta</artifactId>\r
128                 </dependency>\r
129                 <dependency>\r
130                         <groupId>org.onap.aaf.cadi</groupId>\r
131                         <artifactId>cadi-aaf</artifactId>\r
132                 </dependency>   \r
133         </dependencies>\r
134         \r
135         <build>\r
136             <plugins>\r
137                 <plugin>\r
138                 <groupId>org.apache.maven.plugins</groupId>\r
139                 <artifactId>maven-resources-plugin</artifactId>\r
140                 <version>2.7</version>\r
141                 <executions>\r
142                     <execution>\r
143                         <id>copy-docker-file</id>\r
144                         <phase>package</phase>\r
145                         <goals>\r
146                             <goal>copy-resources</goal>\r
147                         </goals>\r
148                         <configuration>\r
149                             <outputDirectory>${dockerLocation}</outputDirectory>\r
150                             <overwrite>true</overwrite>\r
151                             <resources>\r
152                                 <resource>\r
153                                     <directory>${basedir}/src/main/resources/docker</directory>\r
154                                     <filtering>true</filtering>\r
155                                     <includes>\r
156                                         <include>**/*</include>\r
157                                     </includes>\r
158                                 </resource>\r
159                             </resources>\r
160                         </configuration>\r
161                     </execution>\r
162                 </executions>\r
163             </plugin>\r
164                         <plugin>\r
165                 <groupId>com.spotify</groupId>\r
166                 <artifactId>docker-maven-plugin</artifactId>\r
167                 <version>0.4.11</version>\r
168                 <configuration>\r
169                     <imageName>onap/aaf/authz-service</imageName>\r
170                     <dockerDirectory>${dockerLocation}</dockerDirectory>\r
171                     <serverId>docker-hub</serverId>\r
172                      <registryUrl>https://${docker.registry}</registryUrl>\r
173                     <imageTags>\r
174                         <imageTag>${project.version}</imageTag>\r
175                         <imageTag>latest</imageTag>\r
176                     </imageTags>\r
177                                              <resources>\r
178                                 <resource>\r
179                                                                 <targetPath>/</targetPath>\r
180                                     <directory>/${basedir}/target/opt</directory>\r
181                                     <filtering>true</filtering>\r
182                                     <includes>\r
183                                         <include>**/*</include>\r
184                                     </includes>\r
185                                 </resource>\r
186                             </resources>\r
187                     <forceTags>true</forceTags>\r
188                 </configuration>\r
189             </plugin>\r
190                         <plugin>\r
191     <artifactId>maven-resources-plugin</artifactId>\r
192     <version>2.7</version>\r
193     <executions>\r
194       <execution>\r
195         <id>copy-resources-1</id>\r
196         <phase>validate</phase>\r
197         <goals>\r
198           <goal>copy-resources</goal>\r
199         </goals>\r
200         <configuration>\r
201          <outputDirectory>${project.build.directory}/opt/dme2reg/</outputDirectory>\r
202           <resources>\r
203             <resource>\r
204                         <directory>${project.basedir}/src/main/resources/dme2reg/</directory> \r
205                                                  <includes>\r
206                                                  <include>**/*.txt</include>\r
207                         </includes>\r
208                     </resource>\r
209           </resources>\r
210         </configuration>\r
211       </execution>\r
212       <execution>\r
213         <id>copy-resources-2</id>\r
214         <phase>validate</phase>\r
215         <goals>\r
216           <goal>copy-resources</goal>\r
217         </goals>\r
218         <configuration>\r
219           <outputDirectory>${project.build.directory}/opt/app/aaf/authz-service/${project.version}/etc</outputDirectory>\r
220           <resources>\r
221             <resource>\r
222                         <directory>${project.basedir}/src/main/resources/etc</directory>\r
223                         <includes>\r
224                             <include>**/**</include>\r
225                         </includes>\r
226                     </resource>\r
227           </resources>\r
228         </configuration>\r
229       </execution>\r
230           \r
231            <execution>\r
232         <id>copy-resources-3</id>\r
233         <phase>validate</phase>\r
234         <goals>\r
235           <goal>copy-resources</goal>\r
236         </goals>\r
237         <configuration>\r
238           <outputDirectory>${project.build.directory}/opt/app/aaf/authz-service/${project.version}/lib</outputDirectory>\r
239           <resources>\r
240             <resource>\r
241                         <directory>${project.basedir}/../authz-cmd/target</directory>\r
242                         <includes>\r
243                             <include>**/authz-cmd-1.0.0-SNAPSHOT-jar-with-dependencies.jar</include>\r
244                         </includes>\r
245                     </resource>\r
246           </resources>\r
247         </configuration>\r
248       </execution>\r
249           <execution>\r
250         <id>copy-resources-4</id>\r
251         <phase>validate</phase>\r
252         <goals>\r
253           <goal>copy-resources</goal>\r
254         </goals>\r
255         <configuration>\r
256           <outputDirectory>${project.build.directory}/opt/app/aaf/authz-service/${project.version}</outputDirectory>\r
257           <resources>\r
258             <resource>\r
259                         <directory>${project.basedir}/../authz-cmd</directory>\r
260                         <includes>\r
261                             <include>**/aafcli.sh</include>\r
262                         </includes>\r
263                     </resource>\r
264           </resources>\r
265         </configuration>\r
266       </execution>\r
267            <execution>\r
268         <id>copy-resources-5</id>\r
269         <phase>validate</phase>\r
270         <goals>\r
271           <goal>copy-resources</goal>\r
272         </goals>\r
273         <configuration>\r
274           <outputDirectory>${project.build.directory}/opt/app/aaf/authz-service/${project.version}/etc</outputDirectory>\r
275           <resources>\r
276             <resource>\r
277                         <directory>${project.basedir}/../authz-cmd/etc</directory>\r
278                         <includes>\r
279                             <include>**/**</include>\r
280                         </includes>\r
281                     </resource>\r
282           </resources>\r
283         </configuration>\r
284       </execution>\r
285     </executions>\r
286   </plugin>\r
287                         <plugin>\r
288                                 <groupId>org.apache.maven.plugins</groupId>\r
289                                 <artifactId>maven-dependency-plugin</artifactId>\r
290                                 <version>2.10</version>\r
291                                 <executions>\r
292                                         <execution>\r
293                                                 <id>copy-dependencies</id>\r
294                                                 <phase>package</phase>\r
295                                                 <goals>\r
296                                                         <goal>copy-dependencies</goal>\r
297                                                 </goals>\r
298                                                 <configuration>\r
299                                                         <outputDirectory>${project.build.directory}/opt/app/aaf/authz-service/${project.version}/lib</outputDirectory>\r
300                                                         <overWriteReleases>false</overWriteReleases>\r
301                                                         <overWriteSnapshots>false</overWriteSnapshots>\r
302                                                         <overWriteIfNewer>true</overWriteIfNewer>\r
303                                                 </configuration>\r
304                                         </execution>\r
305                                 </executions>\r
306                         </plugin>\r
307                                 \r
308                     <plugin>\r
309                         <groupId>org.codehaus.mojo</groupId>\r
310                         <artifactId>exec-maven-plugin</artifactId>\r
311                         <version>1.5.0</version>\r
312                         <configuration>\r
313                             <executable>java</executable>\r
314                             <arguments>\r
315                                 <argument>-DAFT_LATITUDE=33</argument>\r
316                                 <argument>-DAFT_LONGITUDE=-84</argument>\r
317                                 <argument>-DAFT_ENVIRONMENT=AFTUAT</argument>\r
318         \r
319                                 <argument>-XX:NewRatio=3</argument>\r
320                                 <argument>-XX:+PrintGCTimeStamps</argument>\r
321                                 <argument>-XX:+PrintGCDetails</argument>\r
322                                 <argument>-Xloggc:gc.log</argument>\r
323                                 <argument>-classpath</argument>\r
324         \r
325                                 <classpath>\r
326                                 \r
327                                 </classpath>\r
328                                 <argument>org.onap.aaf.authz.service.AuthAPI</argument>\r
329         \r
330                            <argument>service=org.onap.aaf.authz.AuthorizationService/version=2.0/envContext=DEV/routeOffer=Dev</argument>\r
331                             </arguments>\r
332                         </configuration>\r
333                     </plugin>\r
334         \r
335                     <plugin>\r
336                                 <groupId>org.apache.maven.plugins</groupId>\r
337                                 <artifactId>maven-jar-plugin</artifactId>\r
338                                         <configuration>\r
339                                                 <excludes>\r
340                                 <exclude>*.properties</exclude>\r
341                                 </excludes>\r
342                                         </configuration>\r
343                                         <version>2.3.1</version>\r
344                                 </plugin>\r
345 \r
346                                 <plugin>\r
347                                         <groupId>org.apache.maven.plugins</groupId>\r
348                                         <artifactId>maven-deploy-plugin</artifactId>\r
349                                         <configuration>\r
350                                                 <skip>true</skip>\r
351                                         </configuration>\r
352                             </plugin>  \r
353 \r
354                 <plugin>\r
355                         <groupId>org.apache.maven.plugins</groupId>\r
356                         <artifactId>maven-javadoc-plugin</artifactId>\r
357                         <configuration>\r
358                         <failOnError>false</failOnError>\r
359                         </configuration>\r
360                         <executions>\r
361                                 <execution>\r
362                                         <id>attach-javadocs</id>\r
363                                         <goals>\r
364                                                 <goal>jar</goal>\r
365                                         </goals>\r
366                                 </execution>\r
367                         </executions>\r
368                 </plugin> \r
369            \r
370            \r
371                <plugin>\r
372                       <groupId>org.apache.maven.plugins</groupId>\r
373                       <artifactId>maven-source-plugin</artifactId>\r
374                       <version>2.2.1</version>\r
375                       <executions>\r
376                         <execution>\r
377                           <id>attach-sources</id>\r
378                           <goals>\r
379                             <goal>jar-no-fork</goal>\r
380                           </goals>\r
381                         </execution>\r
382                       </executions>\r
383                     </plugin>\r
384                         \r
385 <plugin>\r
386                                 <groupId>org.sonatype.plugins</groupId>\r
387                                 <artifactId>nexus-staging-maven-plugin</artifactId>\r
388                                 <version>1.6.7</version>\r
389                                 <extensions>true</extensions>\r
390                                 <configuration>\r
391                                         <nexusUrl>${nexusproxy}</nexusUrl>\r
392                                         <stagingProfileId>176c31dfe190a</stagingProfileId>\r
393                                         <serverId>ecomp-staging</serverId>\r
394                                 </configuration>\r
395                         </plugin>               \r
396                         <plugin>\r
397                                 <groupId>org.jacoco</groupId>\r
398                                 <artifactId>jacoco-maven-plugin</artifactId>\r
399                                 <version>0.7.7.201606060606</version>\r
400                                 <configuration>\r
401                                         <dumpOnExit>true</dumpOnExit>\r
402                                         <includes>\r
403                                                 <include>org.onap.aaf.*</include>\r
404                                         </includes>\r
405                                 </configuration>\r
406                                 <executions>\r
407                                         <execution>\r
408                                                 <id>pre-unit-test</id>\r
409                                                 <goals>\r
410                                                         <goal>prepare-agent</goal>\r
411                                                 </goals>\r
412                                                 <configuration>\r
413                                                         <destFile>${project.build.directory}/coverage-reports/jacoco.exec</destFile>\r
414                                                         <!-- <append>true</append> -->\r
415                                                 </configuration>\r
416                                         </execution>\r
417                                         <execution>\r
418                                                 <id>pre-integration-test</id>\r
419                                                 <phase>pre-integration-test</phase>\r
420                                                 <goals>\r
421                                                         <goal>prepare-agent</goal>\r
422                                                 </goals>\r
423                                                 <configuration>\r
424                                                         <destFile>${project.build.directory}/coverage-reports/jacoco-it.exec</destFile>\r
425                                                         <!-- <append>true</append> -->\r
426                                                 </configuration>\r
427                                         </execution>\r
428                                         <execution>\r
429                         <goals>\r
430                             <goal>merge</goal>\r
431                         </goals>\r
432                         <phase>post-integration-test</phase>\r
433                         <configuration>\r
434                             <fileSets>\r
435                                 <fileSet implementation="org.apache.maven.shared.model.fileset.FileSet">\r
436                                     <directory>${project.build.directory}/coverage-reports</directory>\r
437                                     <includes>\r
438                                         <include>*.exec</include>\r
439                                     </includes>\r
440                                 </fileSet>\r
441                             </fileSets>\r
442                             <destFile>${project.build.directory}/jacoco-dev.exec</destFile>\r
443                         </configuration>\r
444                     </execution>\r
445                                 </executions>\r
446                         </plugin>\r
447                 \r
448                         </plugins>\r
449 \r
450         </build>\r
451 \r
452                 <distributionManagement>\r
453                 <repository>\r
454                         <id>ecomp-releases</id>\r
455                         <name>AAF Release Repository</name>\r
456                         <url>${nexusproxy}${releaseNexusPath}</url>\r
457                 </repository>\r
458                 <snapshotRepository>\r
459                         <id>ecomp-snapshots</id>\r
460                         <name>AAF Snapshot Repository</name>\r
461                         <url>${nexusproxy}${snapshotNexusPath}</url>\r
462                 </snapshotRepository>\r
463                 <site>\r
464                         <id>ecomp-site</id>\r
465                         <url>dav:${nexusproxy}${sitePath}</url>\r
466                 </site>\r
467         </distributionManagement>\r
468 <pluginRepositories>\r
469         <pluginRepository>\r
470             <id>onap-plugin-snapshots</id>\r
471             <url>https://nexus.onap.org/content/repositories/snapshots/</url>\r
472         </pluginRepository>\r
473     </pluginRepositories>\r
474         \r
475         <repositories>\r
476                 <repository>\r
477                         <id>central</id>\r
478                         <name>Maven 2 repository 2</name>\r
479                         <url>http://repo2.maven.org/maven2/</url>\r
480                 </repository>\r
481                 <repository>\r
482             <id>onap-jar-snapshots</id>\r
483             <url>https://nexus.onap.org/content/repositories/snapshots</url>\r
484         </repository>\r
485                 <repository>\r
486                         <id>spring-repo</id>\r
487                         <name>Spring repo</name>\r
488                         <url>https://artifacts.alfresco.com/nexus/content/repositories/public/</url>\r
489                 </repository>\r
490                 <repository>\r
491                         <id>repository.jboss.org-public</id>\r
492                         <name>JBoss.org Maven repository</name>\r
493                         <url>https://repository.jboss.org/nexus/content/groups/public</url>\r
494                 </repository>\r
495         </repositories>\r
496 </project>\r