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

    <properties>
        <version.fastdfs>1.25</version.fastdfs>
        <version.fastdfs>1.2.17</version.fastdfs>

    </properties>

    <parent>
        <groupId>cn.stylefeng</groupId>
        <artifactId>guns-separation</artifactId>
        <version>1.1.0</version>
        <relativePath>../pom.xml</relativePath>
    </parent>

    <artifactId>guns-main</artifactId>

    <packaging>jar</packaging>

    <dependencies>

        <dependency>
            <groupId>cn.stylefeng</groupId>
            <artifactId>guns-system</artifactId>
            <version>1.1.0</version>
        </dependency>

        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-test</artifactId>
            <scope>test</scope>
        </dependency>

        <dependency>
            <groupId>org.json</groupId>
            <artifactId>json</artifactId>
            <version>20160212</version>
        </dependency>

        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-data-jpa</artifactId>
        </dependency>

  <!--  解决 Illegal DefaultValue null for parameter type integer    异常  -->
         <dependency>
             <groupId>io.swagger</groupId>
             <artifactId>swagger-annotations</artifactId>
             <version>1.5.21</version>
         </dependency>
         <dependency>
             <groupId>io.swagger</groupId>
             <artifactId>swagger-models</artifactId>
             <version>1.5.21</version>
         </dependency>

        <!-- https://mvnrepository.com/artifact/commons-io/commons-io -->
        <dependency>
            <groupId>commons-io</groupId>
            <artifactId>commons-io</artifactId>
            <version>2.5</version>
        </dependency>


        <!--fastdfs start-->
        <dependency>
            <groupId>org.csource</groupId>
            <artifactId>fastdfs_lib</artifactId>
        </dependency>
        <!--fastdfs end-->

        <!--fastdfs start-->
        <dependency>
            <groupId>org.csource</groupId>
            <artifactId>fastdfs_lib</artifactId>
            <version>${version.fastdfs}</version>
        </dependency>
        <!--fastdfs end-->

    </dependencies>

    <build>
        <finalName>guns-separation</finalName>
        <plugins>
            <plugin>
                <groupId>org.springframework.boot</groupId>
                <artifactId>spring-boot-maven-plugin</artifactId>
                <executions>
                    <execution>
                        <goals>
                            <goal>repackage</goal>
                        </goals>
                    </execution>
                </executions>
                <configuration>
                    <!-- 如果没有该项配置，则devtools不会起作用，即应用不会restart -->
                    <fork>true</fork>
                </configuration>
            </plugin>
            <plugin>
                <groupId>io.fabric8</groupId>
                <artifactId>docker-maven-plugin</artifactId>
                <version>0.26.1</version>
                <configuration>
                    <dockerHost>tcp://demo.stylefeng.cn:2376</dockerHost>
                    <certPath>_dockerCerts</certPath>
                    <images>
                        <image>
                            <alias>service</alias>
                            <name>stylefeng/${project.artifactId}-advanced:latest</name>
                            <build>
                                <from>java:8</from>
                                <assembly>
                                    <descriptor>docker-assembly.xml</descriptor>
                                </assembly>
                                <cmd>
                                    <shell>java -jar /maven/${project.artifactId}.jar</shell>
                                </cmd>
                            </build>
                        </image>
                    </images>
                </configuration>
            </plugin>
        </plugins>
    </build>

</project>
