diff options
Diffstat (limited to 'certService/pom.xml')
-rw-r--r-- | certService/pom.xml | 132 |
1 files changed, 91 insertions, 41 deletions
diff --git a/certService/pom.xml b/certService/pom.xml index 38c356c4..3f17f390 100644 --- a/certService/pom.xml +++ b/certService/pom.xml @@ -16,31 +16,16 @@ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd"> <modelVersion>4.0.0</modelVersion> <parent> - <groupId>org.onap.aaf</groupId> - <artifactId>aaf-certservice-parent</artifactId> - <version>0.0.1-SNAPSHOT</version> + <groupId>org.onap.aaf.certservice</groupId> + <artifactId>aaf-certservice</artifactId> + <version>1.0.0-SNAPSHOT</version> </parent> - <artifactId>cert-service</artifactId> - <version>0.0.1-SNAPSHOT</version> - <name>cert-service</name> - <description>Certification service</description> + <artifactId>aaf-certservice-api</artifactId> + <version>1.0.0-SNAPSHOT</version> + <name>aaf-certservice-api</name> + <description>AAF Certification Service Api</description> <packaging>jar</packaging> - <properties> - <java.version>11</java.version> - <assertj-core.version>3.11.1</assertj-core.version> - <mockito-core.version>3.2.4</mockito-core.version> - <spring-core.version>5.2.3.RELEASE</spring-core.version> - <spring-boot-starter.version>2.2.4.RELEASE</spring-boot-starter.version> - <maven-javadoc-plugin.version>3.0.1</maven-javadoc-plugin.version> - <maven-surefire-plugin.version>3.0.0-M1</maven-surefire-plugin.version> - <spring-boot-starter-actuator.version>2.2.4.RELEASE</spring-boot-starter-actuator.version> - <spring-boot-starter-log4j2.version>2.1.5.RELEASE</spring-boot-starter-log4j2.version> - <springdoc-openapi-ui.version>1.2.21</springdoc-openapi-ui.version> - <bouncycastle.version>1.60</bouncycastle.version> - <docker-maven-plugin.version>0.33.0</docker-maven-plugin.version> - </properties> - <dependencyManagement> <dependencies> <dependency> @@ -115,6 +100,11 @@ <artifactId>bcprov-jdk15on</artifactId> <version>${bouncycastle.version}</version> </dependency> + <dependency> + <groupId>com.google.code.gson</groupId> + <artifactId>gson</artifactId> + <version>${gson.version}</version> + </dependency> </dependencies> <build> @@ -134,7 +124,6 @@ <artifactId>maven-surefire-plugin</artifactId> <version>${maven-surefire-plugin.version}</version> </plugin> - </plugins> </pluginManagement> <plugins> @@ -147,6 +136,18 @@ <goal>repackage</goal> </goals> </execution> + <execution> + <id>pre-integration-test</id> + <goals> + <goal>start</goal> + </goals> + </execution> + <execution> + <id>post-integration-test</id> + <goals> + <goal>stop</goal> + </goals> + </execution> </executions> </plugin> <plugin> @@ -173,15 +174,46 @@ </execution> </executions> </plugin> + <plugin> + <groupId>org.springdoc</groupId> + <artifactId>springdoc-openapi-maven-plugin</artifactId> + <version>${springdoc-openapi-maven-plugin.version}</version> + <executions> + <execution> + <phase>integration-test</phase> + <goals> + <goal>generate</goal> + </goals> + </execution> + </executions> + <configuration> + <apiDocsUrl>${springdoc-openapi-maven-plugin.apiDocsUrl}</apiDocsUrl> + <outputFileName>api-docs.json</outputFileName> + <outputDir>${project.build.directory}</outputDir> + </configuration> + </plugin> </plugins> </build> <profiles> <profile> + <id>docker-staging</id> + <properties> + <docker.tag>${project.version}-STAGING-${maven.build.timestamp}</docker.tag> + <docker.latest.tag>${project.version}-STAGING-latest</docker.latest.tag> + </properties> + </profile> + + <profile> <id>docker</id> <activation> <activeByDefault>false</activeByDefault> </activation> + <properties> + <os.detected.name>linux</os.detected.name> + <os.detected.arch>x86_64</os.detected.arch> + <os.detected.classifier>${os.detected.name}-${os.detected.arch}</os.detected.classifier> + </properties> <build> <plugins> <plugin> @@ -190,38 +222,38 @@ <version>${docker-maven-plugin.version}</version> <executions> <execution> - <id>start</id> - <phase>pre-integration-test</phase> + <id>docker-build-image</id> + <phase>package</phase> <goals> <goal>build</goal> - <goal>start</goal> </goals> </execution> <execution> - <id>stop</id> - <phase>post-integration-test</phase> + <id>docker-push-image</id> + <phase>deploy</phase> <goals> - <goal>stop</goal> + <goal>push</goal> </goals> </execution> </executions> <configuration> + <skipPush>${skipDockerPush}</skipPush> + <verbose>true</verbose> + <imagePullPolicy>IfNotPresent</imagePullPolicy> <images> <image> - <name>cert-service</name> + <alias>${project.artifactId}</alias> + <name>${docker-image.namespace}/${docker-image.name} + </name> + <registry>${docker-image.registry}</registry> <build> - <dockerFile>${project.basedir}/Dockerfile</dockerFile > + <dockerFileDir>${project.basedir}</dockerFileDir> + <tags> + <tag>${project.version}-${maven.build.timestamp}Z</tag> + <tag>${project.version}</tag> + <tag>${docker-image.latest}</tag> + </tags> </build> - <run> - <ports> - <port>8080:8080</port> - </ports> - <wait> - <!-- Check for this URL to return a 200 return code .... --> - <url>http://localhost:8080/actuator/health</url> - <time>120000</time> - </wait> - </run> </image> </images> </configuration> @@ -230,4 +262,22 @@ </build> </profile> </profiles> + + <distributionManagement> + <repository> + <id>ecomp-releases</id> + <name>AAF Release Repository</name> + <url>${nexusproxy}${releaseNexusPath}</url> + </repository> + <snapshotRepository> + <id>ecomp-snapshots</id> + <name>AAF Snapshot Repository</name> + <url>${nexusproxy}${snapshotNexusPath}</url> + </snapshotRepository> + <site> + <id>ecomp-site</id> + <url>dav:${nexusproxy}${sitePath}</url> + </site> + </distributionManagement> + </project> |