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

     Copyright 2005-2015 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>
  <parent>
    <groupId>io.fabric8.forge</groupId>
    <artifactId>forge-addons</artifactId>
    <version>2.3.80</version>
  </parent>
  <artifactId>devops</artifactId>
  <name>Fabric8 :: Forge Addons :: DevOps</name>

  <properties>

    <!-- versions used in spring-boot new-project command for additional choices -->
    <fabric8.spring.cloud.kubernetes.version>0.0.13</fabric8.spring.cloud.kubernetes.version>
    <fabric8.kubeflix.version>1.0.17</fabric8.kubeflix.version>
    <el.version>3.0.0</el.version>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    <maven.compiler.source>1.8</maven.compiler.source>
    <maven.compiler.target>1.8</maven.compiler.target>
  </properties>

  <dependencyManagement>
    <dependencies>
      <dependency>
        <groupId>io.fabric8</groupId>
        <artifactId>fabric8-project</artifactId>
        <version>${fabric8.version}</version>
        <type>pom</type>
        <scope>import</scope>
      </dependency>
      <dependency>
        <groupId>org.jboss.forge</groupId>
        <artifactId>forge-bom</artifactId>
        <version>${jboss.forge.version}</version>
        <type>pom</type>
        <scope>import</scope>
      </dependency>
    </dependencies>
  </dependencyManagement>

  <dependencies>
    <dependency>
      <groupId>io.fabric8.forge</groupId>
      <artifactId>utils</artifactId>
      <version>${project.version}</version>
    </dependency>

    <!-- http client for spring-boot command -->
<!--
    <dependency>
      <groupId>com.squareup.okhttp3</groupId>
      <artifactId>okhttp</artifactId>
      <version>3.0.0</version>
    </dependency>
-->
    <!-- yaml parser to load spring-boot dependency choices -->
    <dependency>
      <groupId>org.yaml</groupId>
      <artifactId>snakeyaml</artifactId>
      <version>1.17</version>
    </dependency>

    <!-- we use dtos with jackson annotations -->
    <dependency>
      <groupId>com.fasterxml.jackson.core</groupId>
      <artifactId>jackson-core</artifactId>
    </dependency>
    <dependency>
      <groupId>com.fasterxml.jackson.core</groupId>
      <artifactId>jackson-annotations</artifactId>
    </dependency>
    <dependency>
      <groupId>com.fasterxml.jackson.core</groupId>
      <artifactId>jackson-databind</artifactId>
    </dependency>

    <dependency>
      <groupId>org.jboss.forge.furnace.container</groupId>
      <artifactId>cdi</artifactId>
      <classifier>forge-addon</classifier>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>org.jboss.forge.addon</groupId>
      <artifactId>slf4j</artifactId>
      <classifier>forge-addon</classifier>
    </dependency>
    <dependency>
      <groupId>org.jboss.forge.addon</groupId>
      <artifactId>core</artifactId>
      <classifier>forge-addon</classifier>
      <exclusions>
        <exclusion>
          <groupId>org.jboss.forge.addon</groupId>
          <artifactId>slf4j</artifactId>
        </exclusion>
        <exclusion>
          <groupId>org.slf4j</groupId>
          <artifactId>slf4j-api</artifactId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>org.jboss.forge.addon</groupId>
      <artifactId>bean-validation</artifactId>
      <classifier>forge-addon</classifier>
    </dependency>
    <dependency>
      <groupId>io.fabric8</groupId>
      <artifactId>kubernetes-api</artifactId>
      <exclusions>
        <exclusion>
          <groupId>org.slf4j</groupId>
          <artifactId>slf4j-api</artifactId>
        </exclusion>
        <exclusion>
          <groupId>org.slf4j</groupId>
          <artifactId>jul-to-slf4j</artifactId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>io.fabric8</groupId>
      <artifactId>letschat-api</artifactId>
      <exclusions>
        <exclusion>
          <groupId>org.slf4j</groupId>
          <artifactId>slf4j-api</artifactId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>io.fabric8</groupId>
      <artifactId>taiga-api</artifactId>
    </dependency>
    <dependency>
      <groupId>io.fabric8</groupId>
      <artifactId>fabric8-devops-connector</artifactId>
      <exclusions>
        <exclusion>
          <groupId>org.slf4j</groupId>
          <artifactId>slf4j-api</artifactId>
        </exclusion>
        <exclusion>
          <groupId>org.slf4j</groupId>
          <artifactId>slf4j-log4j12</artifactId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>io.fabric8</groupId>
      <artifactId>fabric8-devops</artifactId>
    </dependency>
    <dependency>
      <groupId>io.fabric8</groupId>
      <artifactId>fabric8-utils</artifactId>
      <exclusions>
        <exclusion>
          <groupId>org.slf4j</groupId>
          <artifactId>slf4j-api</artifactId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>javax.el</groupId>
      <artifactId>javax.el-api</artifactId>
    </dependency>
    <dependency>
      <groupId>org.glassfish.web</groupId>
      <artifactId>javax.el</artifactId>
    </dependency>

    <!-- testing -->
    <dependency>
      <groupId>org.jboss.forge.furnace.test</groupId>
      <artifactId>furnace-test-harness</artifactId>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.jboss.forge.furnace.test</groupId>
      <artifactId>arquillian-furnace-classpath</artifactId>
      <scope>test</scope>
    </dependency>
  </dependencies>

  <build>
    <finalName>devops</finalName>
    <plugins>
      <plugin>
        <artifactId>maven-jar-plugin</artifactId>
        <executions>
          <execution>
            <id>create-forge-addon</id>
            <phase>package</phase>
            <goals>
              <goal>jar</goal>
            </goals>
            <configuration>
              <classifier>forge-addon</classifier>
            </configuration>
          </execution>
        </executions>
      </plugin>
    </plugins>
  </build>

  <profiles>
    <profile>
      <id>release</id>
      <activation />
      <build>
        <plugins>
          <plugin>
            <groupId>org.jboss.forge.furnace</groupId>
            <artifactId>furnace-maven-plugin</artifactId>
            <version>${furnace.version}</version>
            <executions>
              <execution>
                <id>generate-dot</id>
                <phase>prepare-package</phase>
                <goals>
                  <goal>generate-dot</goal>
                </goals>
                <configuration>
                  <attach>true</attach>
                </configuration>
              </execution>
            </executions>
          </plugin>
        </plugins>
      </build>
    </profile>
  </profiles>
  
</project>
