<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/xsd/maven-4.0.0.xsd">
  <modelVersion>4.0.0</modelVersion>

  <parent>
    <groupId>org.cibseven.bpm</groupId>
    <artifactId>cibseven-database-settings</artifactId>
    <relativePath>../database</relativePath>
    <version>2.0.0</version>
  </parent>

  <groupId>org.cibseven.bpm.springboot.project</groupId>
  <artifactId>cibseven-bpm-spring-boot-starter-root</artifactId>
  <name>CIB seven - Spring Boot Starter - Root Pom</name>
  <inceptionYear>2015</inceptionYear>

  <packaging>pom</packaging>

  <properties>
    <!-- disable parallel unit tests run -->
    <surefire.forkCount>1</surefire.forkCount>
  </properties>

  <dependencyManagement>
    <dependencies>
      <dependency>
        <!-- Import dependency management from Spring Boot -->
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-dependencies</artifactId>
        <version>${version.spring-boot}</version>
        <scope>import</scope>
        <type>pom</type>
      </dependency>
    </dependencies>
  </dependencyManagement>
  
  <profiles>
    <profile>
      <id>distro</id>
      <activation>
        <activeByDefault>true</activeByDefault>
      </activation>
      <modules>
        <module>starter</module>
        <module>starter-rest</module>
        <module>starter-security</module>
        <module>starter-test</module>
        <module>starter-client/spring</module>
        <module>starter-client/spring-boot</module>
        <module>starter-webapp-core</module>
        <module>starter-webapp</module>
        <module>starter-qa</module>
      </modules>
    </profile>
    <profile>
      <id>integration-test-spring-boot-starter</id>
      <modules>
        <!-- All modules that contain *IT.java test classes need to be listed here -->

        <module>starter-qa</module>
        <module>starter</module>
        <module>starter-rest</module>
        <module>starter-security</module>
        <module>starter-client/spring-boot</module>
        <module>starter-webapp-core</module>
      </modules>
      <build>
        <plugins>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-failsafe-plugin</artifactId>
            <!-- 3.0.0-M3 provides support for Junit Jupiter tests -->
            <version>3.0.0-M3</version>
            <executions>
              <execution>
                <goals>
                  <goal>integration-test</goal>
                  <goal>verify</goal>
                </goals>
              </execution>
            </executions>
          </plugin>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-surefire-plugin</artifactId>
            <configuration>
              <skipTests>true</skipTests>
            </configuration>
          </plugin>
        </plugins>
      </build>
    </profile>
  </profiles>

  <build>
    <defaultGoal>clean install</defaultGoal>
    <pluginManagement>
      <plugins>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-jar-plugin</artifactId>
          <configuration>
            <archive>
              <manifest>
                <addDefaultImplementationEntries />
              </manifest>
            </archive>
          </configuration>
        </plugin>
        <!-- set version for spring-boot-maven-plugin because we use the
          spring-boot-parent only in dependencyManagement section, not as parent. -->
        <plugin>
          <groupId>org.springframework.boot</groupId>
          <artifactId>spring-boot-maven-plugin</artifactId>
          <version>${version.spring-boot}</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-failsafe-plugin</artifactId>
          <configuration>
            <redirectTestOutputToFile>true</redirectTestOutputToFile>
            <trimStackTrace>false</trimStackTrace>
          </configuration>
        </plugin>
      </plugins>
    </pluginManagement>

    <plugins>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-enforcer-plugin</artifactId>
        <version>3.0.0-M1</version>
        <configuration>
          <rules>
            <requireJavaVersion>
              <version>[17,)</version>
            </requireJavaVersion>
          </rules>
        </configuration>
        <executions>
          <execution>
            <goals>
              <goal>enforce</goal>
            </goals>
          </execution>
        </executions>
      </plugin>

    </plugins>
  </build>

  <description>
    Description of CIB seven - Spring Boot Starter - Root Pom
  </description>

  <licenses>
    <license>
      <name>The Apache Software License, Version 2.0</name>
      <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
    </license>
  </licenses>

  <organization>
    <name>CIB seven</name>
    <url>https://cibseven.org</url>
  </organization>

  <url>https://cibseven.org</url>

  <developers>
    <developer>
      <id>CIB seven</id>
      <name>CIB seven Community</name>
      <organization>CIB seven</organization>
      <organizationUrl>https://cibseven.org</organizationUrl>
    </developer>
  </developers>

  <scm>
    <url>https://github.com/cibseven/cibseven</url>
    <connection>scm:git:git@github.com:cibseven/cibseven.git</connection>
    <developerConnection>scm:git:git@github.com:cibseven/cibseven.git</developerConnection>
    <tag>HEAD</tag>
  </scm>

  <issueManagement>
    <system>GitHub Issues</system>
    <url>https://github.com/cibseven/cibseven/issues</url>
  </issueManagement>

</project>
