<?xml version="1.0" encoding="UTF-8"?>
<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/maven-v4_0_0.xsd">
  <parent>
    <artifactId>dice-where-build</artifactId>
    <groupId>technology.dice.open</groupId>
    <version>1.2.9</version>
  </parent>
  <modelVersion>4.0.0</modelVersion>
  <artifactId>dice-where-downloader</artifactId>
  <build>
    <resources>
      <resource>
        <filtering>true</filtering>
        <directory>src/main/resources</directory>
      </resource>
    </resources>
    <plugins>
      <plugin>
        <groupId>com.spotify</groupId>
        <artifactId>dockerfile-maven-plugin</artifactId>
        <version>${dockerfile.maven.version}</version>
        <executions>
          <execution>
            <phase>deploy</phase>
            <goals>
              <goal>build</goal>
              <goal>push</goal>
            </goals>
          </execution>
        </executions>
        <configuration>
          <username>${DOCKER_USER}</username>
          <password>${DOCKER_PASSWORD}</password>
          <repository>dicetechnology/dice-where-downloader</repository>
          <tag>${project.version}</tag>
          <buildArgs>
            <JAR_FILE>${project.build.finalName}.jar</JAR_FILE>
          </buildArgs>
          <useMavenSettingsForAuth>true</useMavenSettingsForAuth>
        </configuration>
      </plugin>
      <plugin>
        <artifactId>maven-shade-plugin</artifactId>
        <version>3.2.1</version>
        <executions>
          <execution>
            <phase>package</phase>
            <goals>
              <goal>shade</goal>
            </goals>
            <configuration>
              <transformers>
                <transformer />
                <transformer>
                  <mainClass>technology.dice.dicewhere.downloader.main.Main</mainClass>
                </transformer>
              </transformers>
            </configuration>
          </execution>
        </executions>
        <configuration>
          <filters>
            <filter>
              <artifact>*:*</artifact>
              <excludes>
                <exclude>module-info.class</exclude>
                <exclude>META-INF/*.SF</exclude>
                <exclude>META-INF/*.DSA</exclude>
                <exclude>META-INF/*.RSA</exclude>
              </excludes>
            </filter>
          </filters>
        </configuration>
      </plugin>
    </plugins>
  </build>
  <properties>
    <logback.version>1.2.3</logback.version>
    <dockerfile.maven.version>1.4.13</dockerfile.maven.version>
    <picolli.version>4.1.4</picolli.version>
  </properties>
</project>
