소스 검색

Merge branch 'dev' into feature-cloud

guq 6 년 전
부모
커밋
3e723209f2
1개의 변경된 파일48개의 추가작업 그리고 1개의 파일을 삭제
  1. 48 1
      pom.xml

+ 48 - 1
pom.xml

@@ -537,7 +537,54 @@
                     </plugins>
                 </pluginManagement>
             </build>
-
+        </profile>
+        <profile>
+            <!-- mvn deploy -P docker-prod -->
+            <id>docker-test-cloud</id>
+            <properties>
+                <docker.repository>10.10.100.200:5000</docker.repository>
+            </properties>
+            <build>
+                <pluginManagement>
+                    <plugins>
+                        <!-- Docker maven plugin -->
+                        <plugin>
+                            <groupId>com.spotify</groupId>
+                            <artifactId>docker-maven-plugin</artifactId>
+                            <version>1.0.0</version>
+                            <configuration>
+                                <dockerDirectory>${project.basedir}/src/main/docker</dockerDirectory>
+                                <registryUrl>${docker.repository}</registryUrl>
+                                <pushImage>true</pushImage>
+                                <forceTags>true</forceTags>
+                                <imageName>
+                                    ${docker.repository}/${docker.registry.name}/${project.artifactId}:${project.version}
+                                </imageName>
+                                <imageTags>
+                                    <imageTag>latest</imageTag>
+                                </imageTags>
+                                <resources>
+                                    <resource>
+                                        <targetPath>/</targetPath>
+                                        <directory>${project.build.directory}</directory>
+                                        <include>${project.build.finalName}.jar</include>
+                                    </resource>
+                                </resources>
+                            </configuration>
+                            <executions>
+                                <execution>
+                                    <id>build-image</id>
+                                    <phase>package</phase>
+                                    <goals>
+                                        <goal>build</goal>
+                                    </goals>
+                                </execution>
+                            </executions>
+                        </plugin>
+                        <!-- Docker maven plugin -->
+                    </plugins>
+                </pluginManagement>
+            </build>
         </profile>
         <profile>
             <!-- mvn deploy -P docker-test -->