<?xml version="1.0" encoding="UTF-8"?>
<!--

     Copyright 2005-2014 Red Hat, Inc.

     Red Hat licenses this file to you under the Apache License, version
     2.0 (the "License"); you may not use this file except in compliance
     with the License.  You may obtain a copy of the License at

        http://www.apache.org/licenses/LICENSE-2.0

     Unless required by applicable law or agreed to in writing, software
     distributed under the License is distributed on an "AS IS" BASIS,
     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
     implied.  See the License for the specific language governing
     permissions and limitations under the License.

-->
<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>

  <groupId>io.fabric8</groupId>
  <artifactId>process-spring-boot-bom</artifactId>
  <version>1.2.0.Beta2</version>
  <packaging>pom</packaging>

  <name>Fabric8 :: Process :: Spring Boot BOM</name>
  <description>Fabric8 Spring Boot BOM</description>

  <url>http://fabric8.io/</url>
  <inceptionYear>2011</inceptionYear>

  <organization>
    <name>Red Hat</name>
    <url>http://redhat.com</url>
  </organization>

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

  <!-- including A developer as it's required by the maven poms going into central -->
  <developers>
    <developer>
      <id>geeks</id>
      <name>Fabric8 Development Team</name>
      <organization>fabric8</organization>
      <organizationUrl>http://fabric8.io/</organizationUrl>
    </developer>
  </developers>

  <scm>
    <connection>scm:git:git@github.com:fabric8io/fabric8.git</connection>
    <developerConnection>scm:git:git@github.com:fabric8io/fabric8.git</developerConnection>
    <url>http://github.com/fabric8io/fabric8/tree/master</url>
  </scm>

  <properties>
    <maven.compiler.source>1.7</maven.compiler.source>
    <maven.compiler.target>1.7</maven.compiler.target>

    <spring-boot-version>1.1.5.RELEASE</spring-boot-version>
  </properties>

  <distributionManagement>
    <repository>
      <id>jboss-releases-repository</id>
      <name>JBoss Releases Repository</name>
      <url>https://repository.jboss.org/nexus/service/local/staging/deploy/maven2</url>
    </repository>
  </distributionManagement>

  <dependencyManagement>
    <dependencies>
      <!-- BOMs -->
      <dependency>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-parent</artifactId>
        <version>${spring-boot-version}</version>
        <type>pom</type>
        <scope>import</scope>
      </dependency>
      <dependency>
        <groupId>io.fabric8.bom</groupId>
        <artifactId>fabric8-bom</artifactId>
        <version>${project.version}</version>
        <type>pom</type>
        <scope>import</scope>
      </dependency>

      <!-- BOMed modules -->
      <dependency>
        <groupId>io.fabric8</groupId>
        <artifactId>process-spring-boot-container</artifactId>
        <version>${project.version}</version>
      </dependency>
      <dependency>
        <groupId>io.fabric8</groupId>
        <artifactId>process-spring-boot-registry</artifactId>
        <version>${project.version}</version>
      </dependency>
      <dependency>
        <groupId>io.fabric8</groupId>
        <artifactId>process-spring-boot-starter-activemq</artifactId>
        <version>${project.version}</version>
      </dependency>
      <dependency>
        <groupId>io.fabric8</groupId>
        <artifactId>process-spring-boot-starter-camel</artifactId>
        <version>${project.version}</version>
      </dependency>
    </dependencies>
  </dependencyManagement>

    <build>
        <pluginManagement>
            <plugins>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-source-plugin</artifactId>
                    <version>2.1.2</version>
                </plugin>
                <plugin>
                    <groupId>org.springframework.boot</groupId>
                    <artifactId>spring-boot-maven-plugin</artifactId>
                    <configuration>
                        <mainClass>io.fabric8.process.spring.boot.container.FabricSpringApplication</mainClass>
                    </configuration>
                    <executions>
                        <execution>
                            <goals>
                                <goal>repackage</goal>
                            </goals>
                        </execution>
                    </executions>
                </plugin>
            </plugins>
        </pluginManagement>
    </build>

  <profiles>

  <!--
    Run the release /w the -P release flag to enable the release profile.
  -->
    <profile>
      <id>release</id>
      <build>
        <plugins>

          <!-- We want to sign the artifact, the POM, and all attached artifacts -->
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-gpg-plugin</artifactId>
            <configuration>
              <passphrase>${gpg.passphrase}</passphrase>
            </configuration>
            <executions>
              <execution>
                <goals>
                  <goal>sign</goal>
                </goals>
              </execution>
            </executions>
          </plugin>

          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-source-plugin</artifactId>
            <executions>
              <execution>
                <id>attach-sources</id>
                <goals>
                  <goal>jar-no-fork</goal>
                </goals>
              </execution>
            </executions>
          </plugin>

          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-javadoc-plugin</artifactId>

            <executions>
              <execution>
                <id>attach-javadocs</id>
                <goals>
                  <goal>jar</goal>
                </goals>
              </execution>
            </executions>
          </plugin>

        </plugins>
      </build>
    </profile>
  </profiles>
</project>
