diff options
author | Brian Freeman <bf1936@att.com> | 2019-09-11 18:06:43 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@onap.org> | 2019-09-11 18:06:43 +0000 |
commit | c0135d6f397621fca4c16cfd390e4d848d1d07a7 (patch) | |
tree | 1eff78bd6850bc7dbc948d2f1067eb4cb2cd1b51 /kubernetes/appc/resources | |
parent | bfb4c90d842d1273c310914282e7d195becf3856 (diff) | |
parent | f78f7cfe7941e00db61172b9f2ed9c4e5962cb9d (diff) |
Merge "Move appc install to runtime"
Diffstat (limited to 'kubernetes/appc/resources')
-rwxr-xr-x | kubernetes/appc/resources/config/appc/opt/onap/appc/bin/startODL.sh | 50 |
1 files changed, 24 insertions, 26 deletions
diff --git a/kubernetes/appc/resources/config/appc/opt/onap/appc/bin/startODL.sh b/kubernetes/appc/resources/config/appc/opt/onap/appc/bin/startODL.sh index ad135f863a..c52c6e3aa1 100755 --- a/kubernetes/appc/resources/config/appc/opt/onap/appc/bin/startODL.sh +++ b/kubernetes/appc/resources/config/appc/opt/onap/appc/bin/startODL.sh @@ -111,8 +111,6 @@ then # echo "Copying a working version of the logging configuration into the opendaylight etc folder" # cp ${APPC_HOME}/data/org.ops4j.pax.logging.cfg ${ODL_HOME}/etc/org.ops4j.pax.logging.cfg - echo "Starting OpenDaylight" - ${ODL_HOME}/bin/start echo "Waiting ${SLEEP_TIME} seconds for OpenDaylight to initialize" sleep ${SLEEP_TIME} @@ -137,6 +135,7 @@ then fi echo "Copying the aaa shiro configuration into opendaylight" + mkdir -p ${ODL_HOME}/etc/opendaylight/datastore/initial/config if $ENABLE_AAF then cp ${APPC_HOME}/data/properties/aaa-app-config.xml ${ODL_HOME}/etc/opendaylight/datastore/initial/config/aaa-app-config.xml @@ -144,29 +143,6 @@ then cp ${APPC_HOME}/data/aaa-app-config.xml ${ODL_HOME}/etc/opendaylight/datastore/initial/config/aaa-app-config.xml fi - echo "Restarting OpenDaylight" - ${ODL_HOME}/bin/stop - checkRun () { - running=0 - while read a b c d e f g h - do - if [ "$h" == "/bin/sh /opt/opendaylight/bin/karaf server" ] - then - running=1 - fi - done < <(ps -eaf) - echo $running - } - - while [ $( checkRun ) == 1 ] - do - echo "Karaf is still running, waiting..." - sleep 5s - done - echo "Karaf process has stopped" - sleep 10s - - echo "Installed at `date`" > ${SDNC_HOME}/.installed fi # Move journal and snapshots directory to persistent storage @@ -195,5 +171,27 @@ ln -s ${hostdir}/snapshots ${ODL_HOME}/snapshots echo "Starting cdt-proxy-service jar, logging to ${APPC_HOME}/cdt-proxy-service/jar.log" java -jar ${APPC_HOME}/cdt-proxy-service/cdt-proxy-service.jar > ${APPC_HOME}/cdt-proxy-service/jar.log & -exec ${ODL_HOME}/bin/karaf server +echo "Adding a property system.properties for AAF cadi.properties location" +echo "" >> ${ODL_HOME}/etc/system.properties +echo "cadi_prop_files=${APPC_HOME}/data/properties/cadi.properties" >> ${ODL_HOME}/etc/system.properties +echo "" >> ${ODL_HOME}/etc/system.properties + +echo "Adding a value to property appc.asdc.env in appc.properties for appc-asdc-listener feature" +echo "" >> $APPC_HOME/data/properties/appc.properties +echo "appc.asdc.env=$DMAAP_TOPIC_ENV" >> $APPC_HOME/data/properties/appc.properties +echo "" >> $APPC_HOME/data/properties/appc.properties + +echo "Copying jetty, keystore for https into opendalight" +cp ${APPC_HOME}/data/jetty.xml ${ODL_HOME}/etc/jetty.xml +cp ${APPC_HOME}/data/keystore ${ODL_HOME}/etc/keystore +cp ${APPC_HOME}/data/custom.properties ${ODL_HOME}/etc/custom.properties +echo "Copying a working version of the logging configuration into the opendaylight etc folder" +cp ${APPC_HOME}/data/org.ops4j.pax.logging.cfg ${ODL_HOME}/etc/org.ops4j.pax.logging.cfg + +ODL_BOOT_FEATURES_EXTRA="odl-netconf-connector,odl-restconf-noauth,odl-netconf-clustered-topology,odl-mdsal-clustering" +sed -i -e "\|featuresBoot[^a-zA-Z]|s|$|,${ODL_BOOT_FEATURES_EXTRA}|" $ODL_HOME/etc/org.apache.karaf.features.cfg + +exec ${APPC_HOME}/bin/dockerInstall.sh & +echo "Starting OpenDaylight" +exec ${ODL_HOME}/bin/karaf server |