Hard-code MSO gerrit url 59/5359/4
authorAlexis de Talhouët <adetalhouet89@gmail.com>
Mon, 6 Mar 2017 20:37:39 +0000 (15:37 -0500)
committerAlexis de Talhouët <adetalhouet89@gmail.com>
Tue, 7 Mar 2017 15:52:48 +0000 (15:52 +0000)
env.GIT_NO_PROJECT is only used in Jenkins. Downstream user don't have
knowledge of this variable, but are failing to build because of it.

The gerrit url shouldn't be subject to change, hence hard-coding its
value in a maven property.

Change-Id: Ieed47a282636eafd0556242f56dc0b4d3596ea29
Signed-off-by: Alexis de Talhouët <adetalhouet89@gmail.com>
packages/docker/pom.xml

index c3b566d..6ca79b7 100644 (file)
@@ -18,6 +18,9 @@
        <properties>
                <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
                <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
+               <!-- If the maven profile "docker" is specified the parameter -Dmso.git.url=<MsoGitRepo> must be provided
+                    i.e: mvn clean install -P docker -Dmso.git.url=https://gerrit.openecomp.org/r-->
+               <mso.git.url>${env.GIT_NO_PROJECT}</mso.git.url>
        </properties>
 
        <build>
@@ -35,7 +38,7 @@
                                                </goals>
                                                <phase>initialize</phase>
                                                <configuration>
-                                                       <connectionUrl>scm:git:${env.GIT_NO_PROJECT}/mso/chef-repo</connectionUrl>
+                                                       <connectionUrl>scm:git:${mso.git.url}/mso/chef-repo</connectionUrl>
                                                        <checkoutDirectory>src/main/docker/docker-files/chef-configs/chef-repo</checkoutDirectory>
                                                        <scmVersion>master</scmVersion>
                                                        <scmVersionType>branch</scmVersionType>
@@ -50,7 +53,7 @@
                                                </goals>
                                                <phase>initialize</phase>
                                                <configuration>
-                                                       <connectionUrl>scm:git:${env.GIT_NO_PROJECT}/mso/mso-config</connectionUrl>
+                                                       <connectionUrl>scm:git:${mso.git.url}/mso/mso-config</connectionUrl>
                                                        <checkoutDirectory>src/main/docker/docker-files/chef-configs/mso-config</checkoutDirectory>
                                                        <scmVersion>master</scmVersion>
                                                        <scmVersionType>branch</scmVersionType>