diff --git a/Jenkinsfile b/Jenkinsfile index e38f920801c41f1c1f7e66a651939ebac932b52f..cd238929361e944fcb0cd12cfeeef4e091b5cd05 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -42,18 +42,17 @@ pipeline { } stage('Build UserManager') { - steps { - script { - FAILED_STAGE=env.STAGE_NAME - } - container("maven-17"){ - sh 'mvn --version' - configFileProvider([configFile(fileId: 'maven-settings', variable: 'MAVEN_SETTINGS')]) { - sh 'mvn -s $MAVEN_SETTINGS clean install -Dmaven.wagon.http.retryHandler.count=3' - } - - } - } + steps { + script { + FAILED_STAGE=env.STAGE_NAME + } + container("maven-17"){ + sh 'mvn --version' + configFileProvider([configFile(fileId: 'maven-settings', variable: 'MAVEN_SETTINGS')]) { + sh 'mvn -s $MAVEN_SETTINGS clean install -Dmaven.wagon.http.retryHandler.count=3' + } + } + } } stage('Deploy to Nexus'){ @@ -68,10 +67,9 @@ pipeline { FAILED_STAGE = env.STAGE_NAME } container('maven-17') { - configFileProvider([configFile(fileId: 'maven-settings', variable: 'MAVEN_SETTINGS')]) { - sh 'mvn -s $MAVEN_SETTINGS -DskipTests deploy' - } - + configFileProvider([configFile(fileId: 'maven-settings', variable: 'MAVEN_SETTINGS')]) { + sh 'mvn -s $MAVEN_SETTINGS -DskipTests deploy' + } } } } diff --git a/user-manager/pom.xml b/user-manager/pom.xml new file mode 100644 index 0000000000000000000000000000000000000000..a14429beac583a850f9a052b2552bb04b56ba2c4 --- /dev/null +++ b/user-manager/pom.xml @@ -0,0 +1,231 @@ +<?xml version="1.0"?> +<project + xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd" + xmlns="http://maven.apache.org/POM/4.0.0" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> + <modelVersion>4.0.0</modelVersion> + <groupId>de.itvsh.kop.user</groupId> + <artifactId>user-manager</artifactId> + <version>1.0.0-SNAPSHOT</version> + <name>User Manager</name> + + <properties> + <compiler-plugin.version>3.8.1</compiler-plugin.version> + <maven.compiler.release>17</maven.compiler.release> + <owasp-dependency-check-plugin.version>7.1.1</owasp-dependency-check-plugin.version> + <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> + <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding> + <quarkus.platform.version>2.10.3.Final</quarkus.platform.version> + <skipITs>false</skipITs> + <surefire-plugin.version>3.0.0-M7</surefire-plugin.version> + </properties> + + <dependencyManagement> + <dependencies> + <dependency> + <groupId>io.quarkus.platform</groupId> + <artifactId>quarkus-bom</artifactId> + <version>${quarkus.platform.version}</version> + <type>pom</type> + <scope>import</scope> + </dependency> + </dependencies> + </dependencyManagement> + + <dependencies> + <dependency> + <groupId>io.quarkus</groupId> + <artifactId>quarkus-resteasy-reactive-jackson</artifactId> + </dependency> + <dependency> + <groupId>io.quarkus</groupId> + <artifactId>quarkus-mongodb-panache</artifactId> + </dependency> + <dependency> + <groupId>io.quarkus</groupId> + <artifactId>quarkus-arc</artifactId> + </dependency> + <dependency> + <groupId>io.quarkus</groupId> + <artifactId>quarkus-resteasy-reactive</artifactId> + </dependency> + <dependency> + <groupId>io.quarkus</groupId> + <artifactId>quarkus-spring-web</artifactId> + </dependency> + <!-- <dependency> + <groupId>io.quarkus</groupId> + <artifactId>quarkus-container-image-docker</artifactId> + </dependency> --> + <dependency> + <groupId>io.quarkus</groupId> + <artifactId>quarkus-junit5</artifactId> + <scope>test</scope> + </dependency> + <!--<dependency> + <groupId>io.quarkus</groupId> + <artifactId>quarkus-junit5-mockito</artifactId> + <scope>test</scope> + </dependency> --> + <dependency> + <groupId>io.rest-assured</groupId> + <artifactId>rest-assured</artifactId> + <scope>test</scope> + </dependency> + <dependency> + <groupId>org.testcontainers</groupId> + <artifactId>testcontainers</artifactId> + <scope>test</scope> + </dependency> + <dependency> + <groupId>org.testcontainers</groupId> + <artifactId>mongodb</artifactId> + <scope>test</scope> + </dependency> + <dependency> + <groupId>org.assertj</groupId> + <artifactId>assertj-core</artifactId> + <version>3.23.1</version> + <scope>test</scope> + </dependency> + <dependency> + <groupId>io.quarkus</groupId> + <artifactId>quarkus-jacoco</artifactId> + <scope>test</scope> + </dependency> + <dependency> + <groupId>org.projectlombok</groupId> + <artifactId>lombok</artifactId> + <version>1.18.24</version> + <scope>provided</scope> + </dependency> + </dependencies> + + <build> + <plugins> + <!-- <plugin> + <groupId>org.owasp</groupId> + <artifactId>dependency-check-maven</artifactId> + <version>${owasp-dependency-check-plugin.version}</version> + <configuration> + <failBuildOnCVSS>7</failBuildOnCVSS> + <suppressionFiles> + <suppressionFile>${project.basedir}/dependency-cpe-suppression.xml</suppressionFile> + </suppressionFiles> + </configuration> + </plugin> --> + <plugin> + <groupId>io.quarkus.platform</groupId> + <artifactId>quarkus-maven-plugin</artifactId> + <version>${quarkus.platform.version}</version> + <extensions>true</extensions> + <executions> + <execution> + <goals> + <goal>build</goal> + <goal>generate-code</goal> + <goal>generate-code-tests</goal> + </goals> + </execution> + <!-- <execution> + <id>quarkus</id> + <phase>package</phase> + <goals> + <goal>build</goal> + </goals> + </execution> --> + </executions> + <!-- <configuration> + <uberJar>true</uberJar> + </configuration> --> + </plugin> + <plugin> + <artifactId>maven-compiler-plugin</artifactId> + <version>${compiler-plugin.version}</version> + <configuration> + <!-- <showWarnings>true</showWarnings> --> + <compilerArgs> + <arg>-parameters</arg> + </compilerArgs> + </configuration> + </plugin> + <plugin> + <artifactId>maven-surefire-plugin</artifactId> + <version>${surefire-plugin.version}</version> + <configuration> + <systemPropertyVariables> + <java.util.logging.manager>org.jboss.logmanager.LogManager</java.util.logging.manager> + <maven.home>${maven.home}</maven.home> + </systemPropertyVariables> + </configuration> + </plugin> + <plugin> + <artifactId>maven-failsafe-plugin</artifactId> + <version>${surefire-plugin.version}</version> + <executions> + <execution> + <goals> + <goal>integration-test</goal> + <goal>verify</goal> + </goals> + <configuration> + <systemPropertyVariables> + <native.image.path>${project.build.directory}/${project.build.finalName}-runner</native.image.path> + <java.util.logging.manager>org.jboss.logmanager.LogManager</java.util.logging.manager> + <maven.home>${maven.home}</maven.home> + </systemPropertyVariables> + </configuration> + </execution> + </executions> + <configuration> + <argLine>${surefire.jacoco.args}</argLine> + <classesDirectory>${project.build.outputDirectory}</classesDirectory> + </configuration> + </plugin> + <plugin> + <groupId>pl.project13.maven</groupId> + <artifactId>git-commit-id-plugin</artifactId> + <executions> + <execution> + <id>get-the-git-infos</id> + <phase>initialize</phase> + <goals> + <goal>revision</goal> + </goals> + </execution> + </executions> + <configuration> + <offline>true</offline> + </configuration> + </plugin> + </plugins> + </build> + + <profiles> + <profile> + <id>native</id> + <activation> + <property> + <name>native</name> + </property> + </activation> + <properties> + <skipITs>false</skipITs> + <quarkus.package.type>native</quarkus.package.type> + </properties> + </profile> + </profiles> + + <distributionManagement> + <repository> + <id>ozg-nexus</id> + <name>ozg-releases</name> + <url>https://nexus.ozg-sh.de/repository/ozg-releases/</url> + </repository> + <snapshotRepository> + <id>ozg-snapshots-nexus</id> + <name>ozg-snapshots</name> + <url>https://nexus.ozg-sh.de/repository/ozg-snapshots/</url> + </snapshotRepository> + </distributionManagement> +</project> \ No newline at end of file