Store .installed marker in persistent volume 75/72675/1
authorTimoney, Dan (dt5972) <dtimoney@att.com>
Wed, 14 Nov 2018 15:15:04 +0000 (10:15 -0500)
committerDan Timoney <dtimoney@att.com>
Wed, 14 Nov 2018 16:05:23 +0000 (16:05 +0000)
Store .installed marker in persistent volume (/opt/opendaylight/current/daexim)

Change-Id: If9bad7fcd8a2412d1db7fb3bbb77d5f81f4b7377
Issue-ID: SDNC-518
Signed-off-by: Timoney, Dan (dt5972) <dtimoney@att.com>
(cherry picked from commit 9788155805ded9b76617e6c795c76b53f73426ec)

odlsli/src/main/scripts/startODL.sh

index 8c45dda..4d60857 100644 (file)
@@ -29,6 +29,7 @@ ODL_ADMIN_PASSWORD=${ODL_ADMIN_PASSWORD:-Kp8bJ4SXszM0WXlhak3eHlcse2gAw84vaoGGmJv
 CCSDK_HOME=${CCSDK_HOME:-/opt/onap/ccsdk}
 SLEEP_TIME=${SLEEP_TIME:-120}
 MYSQL_PASSWD=${MYSQL_PASSWD:-openECOMP1.0}
 CCSDK_HOME=${CCSDK_HOME:-/opt/onap/ccsdk}
 SLEEP_TIME=${SLEEP_TIME:-120}
 MYSQL_PASSWD=${MYSQL_PASSWD:-openECOMP1.0}
+INSTALLED_DIR=${INSTALLED_FILE:-/opt/opendaylight/current/daexim}
 
 
 #
 
 
 #
@@ -42,7 +43,12 @@ do
 done
 echo -e "\nmysql ready"
 
 done
 echo -e "\nmysql ready"
 
-if [ ! -f ${CCSDK_HOME}/.installed ]
+if [ ! -d ${INSTALLED_DIR} ]
+then
+    mkdir -p ${INSTALLED_DIR}
+fi
+
+if [ ! -f ${INSTALLED_DIR}/.installed ]
 then
     echo "Installing SDN-C database"
     ${CCSDK_HOME}/bin/installSdncDb.sh
 then
     echo "Installing SDN-C database"
     ${CCSDK_HOME}/bin/installSdncDb.sh
@@ -53,7 +59,7 @@ then
         echo "Installing directed graphs"
         ${CCSDK_HOME}/svclogic/bin/install.sh
     fi
         echo "Installing directed graphs"
         ${CCSDK_HOME}/svclogic/bin/install.sh
     fi
-    echo "Installed at `date`" > ${CCSDK_HOME}/.installed
+    echo "Installed at `date`" > ${INSTALLED_DIR}/.installed
 fi
 
 exec ${ODL_HOME}/bin/karaf server
 fi
 
 exec ${ODL_HOME}/bin/karaf server

© 2017 ONAP. Copyright © The Linux Foundation ®. All Rights Reserved.
The Linux Foundation has registered trademarks and uses trademarks.
For a list of trademarks of The Linux Foundation, please see our Trademark Usage page.
Linux is a registered trademark of Linus Torvalds.
Privacy Policy and Terms of Use