diff options
Diffstat (limited to 'dgbuilder-docker/pom.xml')
-rw-r--r-- | dgbuilder-docker/pom.xml | 133 |
1 files changed, 70 insertions, 63 deletions
diff --git a/dgbuilder-docker/pom.xml b/dgbuilder-docker/pom.xml index a857723b..d5f2df4a 100644 --- a/dgbuilder-docker/pom.xml +++ b/dgbuilder-docker/pom.xml @@ -66,93 +66,64 @@ </execution> </executions> </plugin> - <plugin> - <groupId>org.codehaus.mojo</groupId> - <artifactId>exec-maven-plugin</artifactId> - <version>1.5.0</version> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-antrun-plugin</artifactId> + <version>1.8</version> <executions> <execution> - <id>Make-stage-dir</id> + <id>make-stage-dir</id> <phase>generate-sources</phase> - <goals> - <goal>exec</goal> - </goals> <configuration> - <executable>/bin/mkdir</executable> - <arguments> - <argument>-p</argument> - <argument>${basedir}/target/docker-stage/opt/onap/ccsdk</argument> - </arguments> + <target> + <mkdir dir="${basedir}/target/docker-stage/opt/onap/ccsdk"/> + </target> </configuration> - </execution> - <execution> - <id>Unzip dgbuilder</id> - <phase>generate-sources</phase> <goals> - <goal>exec</goal> + <goal>run</goal> </goals> - <configuration> - <executable>/usr/bin/unzip</executable> - <arguments> - <argument>-d</argument> - <argument>${basedir}/target/docker-stage/opt/onap/ccsdk</argument> - <argument>../dgbuilder/target/*.zip</argument> - </arguments> - </configuration> </execution> <execution> - <id>Copy dgbuilder</id> + <id>unzip-dgbuilder</id> <phase>generate-sources</phase> - <goals> - <goal>exec</goal> - </goals> <configuration> - <executable>/bin/cp</executable> - <arguments> - <argument>-r</argument> - <argument>../dgbuilder</argument> - <argument>${basedir}/target/docker-stage/opt/onap/ccsdk</argument> - </arguments> + <target> + <unzip dest="${basedir}/target/docker-stage/opt/onap/ccsdk"> + <fileset dir="${basedir}/../dgbuilder/target/"> + <include name="**/*.zip"/> + </fileset> + </unzip> + </target> </configuration> + <goals> + <goal>run</goal> + </goals> </execution> - <execution> - <id>dgbuilder createReleaseDir</id> + <id>copy-dgbuilder</id> <phase>generate-sources</phase> - <goals> - <goal>exec</goal> - </goals> <configuration> - <executable>/bin/bash</executable> - <arguments> - <argument>${basedir}/target/docker-stage/opt/onap/ccsdk/dgbuilder/createReleaseDir.sh</argument> - <argument>1702</argument> - <argument>dguser</argument> - <argument>change_email_id@dgbuilder.com</argument> - </arguments> + <target> + <copy todir="${basedir}/target/docker-stage/opt/onap/ccsdk/dgbuilder"> + <fileset dir="${basedir}/../dgbuilder" excludes="target/**"/> + </copy> + </target> </configuration> + <goals> + <goal>run</goal> + </goals> </execution> - <execution> <id>change shell permissions</id> <phase>process-sources</phase> - <goals> - <goal>exec</goal> - </goals> <configuration> - <executable>/usr/bin/find</executable> - <arguments> - <argument>${basedir}/target/docker-stage/opt/onap/ccsdk</argument> - <argument>-name</argument> - <argument>*.sh</argument> - <argument>-exec</argument> - <argument>chmod</argument> - <argument>+x</argument> - <argument>{}</argument> - <argument>;</argument> - </arguments> + <target> + <chmod dir="${basedir}/target/docker-stage/opt/onap/ccsdk" perm="+x" includes="**/*.sh"/> + </target> </configuration> + <goals> + <goal>run</goal> + </goals> </execution> </executions> </plugin> @@ -161,6 +132,42 @@ <profiles> <profile> + <id>unix</id> + <activation> + <os> + <family>unix</family> + </os> + </activation> + <build> + <plugins> + <plugin> + <groupId>org.codehaus.mojo</groupId> + <artifactId>exec-maven-plugin</artifactId> + <version>1.5.0</version> + <executions> + <!-- TODO: Need to see alternate for below, so that it can execute on Windows Environment --> + <execution> + <id>dgbuilder-createReleaseDir</id> + <phase>generate-sources</phase> + <goals> + <goal>exec</goal> + </goals> + <configuration> + <executable>/bin/bash</executable> + <arguments> + <argument>${basedir}/target/docker-stage/opt/onap/ccsdk/dgbuilder/createReleaseDir.sh</argument> + <argument>1702</argument> + <argument>dguser</argument> + <argument>change_email_id@dgbuilder.com</argument> + </arguments> + </configuration> + </execution> + </executions> + </plugin> + </plugins> + </build> + </profile> + <profile> <id>docker</id> <build> <plugins> |