Add build dir to docker build script 41/10141/1
authorfujinhua <fu.jinhua@zte.com.cn>
Mon, 4 Sep 2017 06:20:56 +0000 (14:20 +0800)
committerfujinhua <fu.jinhua@zte.com.cn>
Mon, 4 Sep 2017 06:20:56 +0000 (14:20 +0800)
Change-Id: Ie324dfb080d896be106aa16fead5a50418c762b6
Issue-Id: VFC-256
Signed-off-by: fujinhua <fu.jinhua@zte.com.cn>
lcm/docker/build_image.sh
lcm/pom.xml

index 947803d..52ed777 100755 (executable)
@@ -1,4 +1,8 @@
 #!/bin/bash
+DIRNAME=`dirname $0`
+DOCKER_BUILD_DIR=`cd $DIRNAME/; pwd`
+echo "DOCKER_BUILD_DIR=${DOCKER_BUILD_DIR}"
+cd ${DOCKER_BUILD_DIR}
 
 BUILD_ARGS="--no-cache"
 ORG="onap"
index 4f025d5..7aba16f 100644 (file)
         </plugin>
       </plugins>
     </build>
-    <profiles>
-        <profile>
-            <id>docker</id>
-            <build>
-                <plugins>
-                    <plugin>
-                        <groupId>io.fabric8</groupId>
-                        <artifactId>docker-maven-plugin</artifactId>
-                        <version>0.16.5</version>
-                        <inherited>false</inherited>
-                        <configuration>
-                            <images>
-                                <image>
-                                    <name>onap/vfc/vnflcm</name>
-                                    <build>
-                                        <cleanup>try</cleanup>
-                                        <dockerFileDir>${basedir}/docker/</dockerFileDir>
-                                        <dockerFile>${basedir}/docker/Dockerfile</dockerFile>
-                                        <tags>
-                                            <tag>${project.version}-STAGING-latest</tag>
-                                        </tags>
-                                    </build>
-                                </image>
-                            </images>
-                        </configuration>
-                        <executions>
-                            <execution>
-                                <id>generate-images</id>
-                                <phase>package</phase>
-                                <goals>
-                                    <goal>build</goal>
-                                </goals>
-                            </execution>
-                            <execution>
-                                <id>push-images</id>
-                                <phase>deploy</phase>
-                                <goals>
-                                    <goal>build</goal>
-                                    <goal>push</goal>
-                                </goals>
-                            </execution>
-                        </executions>
-                    </plugin>
-                </plugins>
-            </build>
-        </profile>
-    </profiles>
 </project>