Implement skip_install case exception 51/17351/1
authorVictor Morales <victor.morales@intel.com>
Thu, 5 Oct 2017 15:18:01 +0000 (08:18 -0700)
committerVictor Morales <victor.morales@intel.com>
Thu, 5 Oct 2017 15:18:01 +0000 (08:18 -0700)
The Skip install can be implemented differently for SDC module to
allow specific scenarios where it's necessary to skip the get
images process but install the services.

Change-Id: I491bc6846b25030798e3613d01ec7d14dd08381d
Signed-off-by: Victor Morales <victor.morales@intel.com>
Issue-Id: INT-236

bootstrap/vagrant-onap/lib/sdc

index c7f79d6..1d21e13 100755 (executable)
@@ -96,7 +96,11 @@ function install_sdc {
     sed -i "s/\"fqdn\":.*/\"fqdn\": [\""$MR_IP_ADDR"\", \""$MR_IP_ADDR"\"]/g" /data/environments/$ENV_NAME.json
 
     install_docker
-    bash /data/scripts/docker_run.sh -e $ENV_NAME  -l
+    if [[ "$skip_get_images" == "False" ]]; then
+        bash /data/scripts/docker_run.sh -e $ENV_NAME  -l
+    else
+        bash /data/scripts/docker_run.sh -e $ENV_NAME -r $docker_version -p $(echo $nexus_docker_repo | cut -d':' -f2)
+    fi
 }
 
 # init_sdc() - Function that initialize SDC services
@@ -111,9 +115,9 @@ function init_sdc {
 
     if [[ "$skip_get_images" == "False" ]]; then
         get_sdc_images
-        if [[ "$skip_install" == "False" ]]; then
-            install_sdc
-        fi
+    fi
+    if [[ "$skip_install" == "False" ]]; then
+        install_sdc
     fi
     _setup_docker_aliases
 }