summaryrefslogtreecommitdiffstats
path: root/kubernetes/appc/resources
diff options
context:
space:
mode:
Diffstat (limited to 'kubernetes/appc/resources')
-rwxr-xr-xkubernetes/appc/resources/config/appc/opt/onap/appc/bin/installAppcDb.sh (renamed from kubernetes/appc/resources/config/appc/opt/openecomp/appc/bin/installAppcDb.sh)10
-rwxr-xr-xkubernetes/appc/resources/config/appc/opt/onap/appc/bin/startODL.sh (renamed from kubernetes/appc/resources/config/appc/opt/openecomp/appc/bin/startODL.sh)37
-rw-r--r--kubernetes/appc/resources/config/appc/opt/onap/appc/data/properties/aaiclient.properties (renamed from kubernetes/appc/resources/config/appc/opt/openecomp/appc/data/properties/aaiclient.properties)6
-rw-r--r--kubernetes/appc/resources/config/appc/opt/onap/appc/data/properties/appc.properties (renamed from kubernetes/appc/resources/config/appc/opt/openecomp/appc/data/properties/appc.properties)22
-rw-r--r--kubernetes/appc/resources/config/appc/opt/onap/appc/data/properties/dblib.properties (renamed from kubernetes/appc/resources/config/appc/opt/openecomp/appc/data/properties/dblib.properties)2
-rw-r--r--kubernetes/appc/resources/config/appc/opt/onap/appc/data/properties/svclogic.properties (renamed from kubernetes/appc/resources/config/appc/opt/openecomp/appc/data/properties/svclogic.properties)2
-rwxr-xr-xkubernetes/appc/resources/config/appc/opt/onap/appc/svclogic/bin/showActiveGraphs.sh (renamed from kubernetes/appc/resources/config/appc/opt/openecomp/appc/svclogic/bin/showActiveGraphs.sh)2
-rw-r--r--kubernetes/appc/resources/config/appc/opt/onap/appc/svclogic/config/svclogic.properties (renamed from kubernetes/appc/resources/config/appc/opt/openecomp/appc/svclogic/config/svclogic.properties)2
-rwxr-xr-xkubernetes/appc/resources/config/appc/opt/onap/sdnc/bin/installSdncDb.sh6
-rwxr-xr-xkubernetes/appc/resources/config/appc/opt/onap/sdnc/bin/startODL.sh4
-rw-r--r--kubernetes/appc/resources/config/appc/opt/onap/sdnc/data/properties/aaiclient.properties6
-rw-r--r--kubernetes/appc/resources/config/appc/opt/onap/sdnc/data/properties/dblib.properties2
-rw-r--r--kubernetes/appc/resources/config/appc/opt/onap/sdnc/data/properties/svclogic.properties2
-rwxr-xr-xkubernetes/appc/resources/config/appc/opt/onap/sdnc/svclogic/bin/showActiveGraphs.sh2
-rw-r--r--kubernetes/appc/resources/config/appc/opt/onap/sdnc/svclogic/config/svclogic.properties2
-rw-r--r--kubernetes/appc/resources/config/dgbuilder/svclogic.properties5
-rw-r--r--kubernetes/appc/resources/config/log/filebeat/log4j/filebeat.yml2
-rwxr-xr-xkubernetes/appc/resources/scripts/dgbuilder/createReleaseDir.sh129
-rw-r--r--kubernetes/appc/resources/scripts/dgbuilder/customSettings.js38
19 files changed, 69 insertions, 212 deletions
diff --git a/kubernetes/appc/resources/config/appc/opt/openecomp/appc/bin/installAppcDb.sh b/kubernetes/appc/resources/config/appc/opt/onap/appc/bin/installAppcDb.sh
index 526d6f94ae..f260f3d84a 100755
--- a/kubernetes/appc/resources/config/appc/opt/openecomp/appc/bin/installAppcDb.sh
+++ b/kubernetes/appc/resources/config/appc/opt/onap/appc/bin/installAppcDb.sh
@@ -20,7 +20,7 @@
SDNC_HOME=${SDNC_HOME:-/opt/onap/sdnc}
APPC_HOME=${APPC_HOME:-/opt/openecomp/appc}
-MYSQL_PASSWD=${MYSQL_PASSWD:-openECOMP1.0}
+MYSQL_PASSWD=${MYSQL_PASSWD:-{{.Values.config.dbRootPassword}}}
APPC_DB_USER=${APPC_DB_USER:-appcctl}
APPC_DB_PASSWD=${APPC_DB_PASSWD:-appcctl}
@@ -28,7 +28,7 @@ APPC_DB_DATABASE=${SDN_DB_DATABASE:-appcctl}
# Create tablespace and user account
-mysql -h appc-dbhost.{{.Values.nsPrefix}} -u root -p${MYSQL_PASSWD} mysql <<-END
+mysql -h {{.Values.mysql.service.name}}.{{.Release.Namespace}} -u root -p${MYSQL_PASSWD} mysql <<-END
CREATE DATABASE ${APPC_DB_DATABASE};
CREATE USER '${APPC_DB_USER}'@'localhost' IDENTIFIED BY '${APPC_DB_PASSWD}';
CREATE USER '${APPC_DB_USER}'@'%' IDENTIFIED BY '${APPC_DB_PASSWD}';
@@ -39,16 +39,16 @@ END
if [ -f ${APPC_HOME}/data/appcctl.dump ]
then
- mysql -h appc-dbhost.{{.Values.nsPrefix}} -u root -p${MYSQL_PASSWD} appcctl < ${APPC_HOME}/data/appcctl.dump
+ mysql -h {{.Values.mysql.service.name}}.{{.Release.Namespace}} -u root -p${MYSQL_PASSWD} appcctl < ${APPC_HOME}/data/appcctl.dump
fi
if [ -f ${APPC_HOME}/data/sdnctl.dump ]
then
- mysql -h appc-dbhost.{{.Values.nsPrefix}} -u root -p${MYSQL_PASSWD} sdnctl < ${APPC_HOME}/data/sdnctl.dump
+ mysql -h {{.Values.mysql.service.name}}.{{.Release.Namespace}} -u root -p${MYSQL_PASSWD} sdnctl < ${APPC_HOME}/data/sdnctl.dump
fi
if [ -f ${APPC_HOME}/data/sqlData.dump ]
then
- mysql -h appc-dbhost.{{.Values.nsPrefix}} -u root -p${MYSQL_PASSWD} sdnctl < ${APPC_HOME}/data/sqlData.dump
+ mysql -h {{.Values.mysql.service.name}}.{{.Release.Namespace}} -u root -p${MYSQL_PASSWD} sdnctl < ${APPC_HOME}/data/sqlData.dump
fi
diff --git a/kubernetes/appc/resources/config/appc/opt/openecomp/appc/bin/startODL.sh b/kubernetes/appc/resources/config/appc/opt/onap/appc/bin/startODL.sh
index ba4ff52147..0b9e63127b 100755
--- a/kubernetes/appc/resources/config/appc/opt/openecomp/appc/bin/startODL.sh
+++ b/kubernetes/appc/resources/config/appc/opt/onap/appc/bin/startODL.sh
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/bin/bash -x
###
# ============LICENSE_START=======================================================
@@ -26,12 +26,39 @@
# if not already installed, and starts the APPC Docker Container
#
+function enable_odl_cluster(){
+ if [ -z $APPC_REPLICAS ]; then
+ echo "APPC_REPLICAS is not configured in Env field"
+ exit
+ fi
+
+ echo "Installing Opendaylight cluster features"
+ ${ODL_HOME}/bin/client -u karaf feature:install odl-mdsal-clustering
+ ${ODL_HOME}/bin/client -u karaf feature:install odl-jolokia
+
+ echo "Update cluster information statically"
+ hm=$(hostname)
+ echo "Get current Hostname ${hm}"
+
+ node=($(echo ${hm} | sed 's/-[0-9]*$//g'))
+ node_index=($(echo ${hm} | awk -F"-" '{print $NF}'))
+ node_list="${node}-0.{{ .Values.service.name }}-cluster.{{.Release.Namespace}}";
+
+ for ((i=1;i<${APPC_REPLICAS};i++));
+ do
+ node_list="${node_list} ${node}-$i.{{ .Values.service.name }}-cluster.{{.Release.Namespace}}"
+ done
+
+ /opt/opendaylight/current/bin/configure_cluster.sh $((node_index+1)) ${node_list}
+}
+
ODL_HOME=${ODL_HOME:-/opt/opendaylight/current}
ODL_ADMIN_PASSWORD=${ODL_ADMIN_PASSWORD:-Kp8bJ4SXszM0WXlhak3eHlcse2gAw84vaoGGmJvUy2U}
SDNC_HOME=${SDNC_HOME:-/opt/onap/sdnc}
-APPC_HOME=${APPC_HOME:-/opt/openecomp/appc}
+APPC_HOME=${APPC_HOME:-/opt/onap/appc}
SLEEP_TIME=${SLEEP_TIME:-120}
-MYSQL_PASSWD=${MYSQL_PASSWD:-openECOMP1.0}
+MYSQL_PASSWD=${MYSQL_PASSWD:-{{.Values.config.dbRootPassword}}}
+ENABLE_ODL_CLUSTER=${ENABLE_ODL_CLUSTER:-false}
#
# Adding the DMAAP_TOPIC_ENV variable into APPC-ASDC-LISTENER properties
@@ -55,7 +82,7 @@ echo "" >> $APPC_HOME/data/properties/appc.properties
# Wait for database to init properly
#
echo "Waiting for mysql"
-until mysql -h appc-dbhost.{{.Values.nsPrefix}} -u root -p${MYSQL_PASSWD} mysql &> /dev/null
+until mysql -h {{.Values.mysql.service.name}}.{{.Release.Namespace}} -u root -p{{.Values.config.dbRootPassword}} mysql &> /dev/null
do
printf "."
sleep 1
@@ -97,6 +124,8 @@ then
${APPC_HOME}/svclogic/bin/install-converted-dgs.sh
fi
+ if $ENABLE_ODL_CLUSTER ; then enable_odl_cluster ; fi
+
echo "Restarting OpenDaylight"
${ODL_HOME}/bin/stop
echo "Installed at `date`" > ${SDNC_HOME}/.installed
diff --git a/kubernetes/appc/resources/config/appc/opt/openecomp/appc/data/properties/aaiclient.properties b/kubernetes/appc/resources/config/appc/opt/onap/appc/data/properties/aaiclient.properties
index 9e29744bb3..b2f7102d8c 100644
--- a/kubernetes/appc/resources/config/appc/opt/openecomp/appc/data/properties/aaiclient.properties
+++ b/kubernetes/appc/resources/config/appc/opt/onap/appc/data/properties/aaiclient.properties
@@ -39,7 +39,7 @@ org.onap.ccsdk.sli.adaptors.aai.application=openECOMP
#
# Configuration file for A&AI Client
#
-org.onap.ccsdk.sli.adaptors.aai.uri=https://aai-service.{{.Values.nsPrefix}}:8443
+org.onap.ccsdk.sli.adaptors.aai.uri=https://aai-service.{{.Release.Namespace}}:8443
# query
@@ -133,8 +133,8 @@ org.onap.ccsdk.sli.adaptors.aai.path.vnf.image.query=/aai/v11/service-design-and
# UBB Notify
org.onap.ccsdk.sli.adaptors.aai.path.notify=/aai/v11/actions/notify
-org.onap.ccsdk.sli.adaptors.aai.notify.selflink.fqdn=https://aai-service.{{.Values.nsPrefix}}:8443/restconf/config/L3SDN-API:services/layer3-service-list/{service-instance-id}
-org.onap.ccsdk.sli.adaptors.aai.notify.selflink.avpn=https://aai-service.{{.Values.nsPrefix}}:8443/restconf/config/L3AVPN-EVC-API:services/service-list/{service-instance-id}/service-data/avpn-logicalchannel-information
+org.onap.ccsdk.sli.adaptors.aai.notify.selflink.fqdn=https://aai-service.{{.Release.Namespace}}:8443/restconf/config/L3SDN-API:services/layer3-service-list/{service-instance-id}
+org.onap.ccsdk.sli.adaptors.aai.notify.selflink.avpn=https://aai-service.{{.Release.Namespace}}:8443/restconf/config/L3AVPN-EVC-API:services/service-list/{service-instance-id}/service-data/avpn-logicalchannel-information
# Service
org.onap.ccsdk.sli.adaptors.aai.path.service=/aai/v11/service-design-and-creation/services/service/{service-id}
diff --git a/kubernetes/appc/resources/config/appc/opt/openecomp/appc/data/properties/appc.properties b/kubernetes/appc/resources/config/appc/opt/onap/appc/data/properties/appc.properties
index de577c43cb..f4ee6fcfc7 100644
--- a/kubernetes/appc/resources/config/appc/opt/openecomp/appc/data/properties/appc.properties
+++ b/kubernetes/appc/resources/config/appc/opt/onap/appc/data/properties/appc.properties
@@ -22,7 +22,7 @@
### ###
### Properties for demo ###
### ###
-appc.demo.poolMembers=dmaap.{{.Values.nsPrefix}}:3904
+appc.demo.poolMembers=dmaap.{{.Release.Namespace}}:3904
appc.demo.topic.read=APPC-CL
appc.demo.topic.write=APPC-CL
appc.demo.client.name=appcDemoEventListener
@@ -33,7 +33,7 @@ appc.demo.threads.poolsize.max=2
appc.demo.provider.user=admin
appc.demo.provider.pass=Kp8bJ4SXszM0WXlhak3eHlcse2gAw84vaoGGmJvUy2U
appc.demo.provider.url=http://localhost:8181/restconf/operations/appc-provider
-appc.provider.vfodl.url=http://admin:Kp8bJ4SXszM0WXlhak3eHlcse2gAw84vaoGGmJvUy2U@appc-sdnhost.{{.Values.nsPrefix}}:8282/restconf/config/network-topology:network-topology/topology/topology-netconf/node/NODE_NAME/yang-ext:mount/sample-plugin:sample-plugin/pg-streams/
+appc.provider.vfodl.url=http://admin:Kp8bJ4SXszM0WXlhak3eHlcse2gAw84vaoGGmJvUy2U@appc-sdnhost.{{.Release.Namespace}}:8282/restconf/config/network-topology:network-topology/topology/topology-netconf/node/NODE_NAME/yang-ext:mount/sample-plugin:sample-plugin/pg-streams/
# The properties right below are needed to properly call the Master DG to serve demo purposes
appc.service.logic.module.name=APPC
@@ -41,11 +41,11 @@ appc.topology.dg.method=topology-operation-all
appc.topology.dg.version=2.0.0
# TEMP - Properties that might be needed to make the AAI-APPC connection
-org.openecomp.appc.db.url.appcctl=jdbc:mysql://appc-dbhost.{{.Values.nsPrefix}}:3306/appcctl
+org.openecomp.appc.db.url.appcctl=jdbc:mysql://{{.Values.mysql.service.name}}.{{.Release.Namespace}}:3306/appcctl
org.openecomp.appc.db.user.appcctl=appcctl
org.openecomp.appc.db.pass.appcctl=appcctl
-org.openecomp.appc.db.url.sdnctl=jdbc:mysql://appc-dbhost.{{.Values.nsPrefix}}:3306/sdnctl
+org.openecomp.appc.db.url.sdnctl=jdbc:mysql://{{.Values.mysql.service.name}}.{{.Release.Namespace}}:3306/sdnctl
org.openecomp.appc.db.user.sdnctl=sdnctl
org.openecomp.appc.db.pass.sdnctl=gamma
@@ -74,11 +74,11 @@ provider1.tenant1.password=Kp8bJ4SXszM0WXlhak3eHlcse2gAw84vaoGGmJvUy2U
# Property below is valid in appc-command-executor-core, appc-license-manager-core, appc-lifecycle-management-core,
# appc-request-handler-core, appc-workflow-management-core (all from the appc-dispatcher package).
-dmaap.poolMembers=dmaap.{{.Values.nsPrefix}}:3904
+dmaap.poolMembers=dmaap.{{.Release.Namespace}}:3904
# appc-event-listener-bundle properties (only defined in src/test of default.properties)
-appc.LCM.poolMembers=dmaap.{{.Values.nsPrefix}}:3904
+appc.LCM.poolMembers=dmaap.{{.Release.Namespace}}:3904
appc.LCM.topic.read=APPC-LCM-READ
appc.LCM.topic.write=APPC-LCM-WRITE
appc.LCM.client.name=APPC-EVENT-LISTENER-TEST
@@ -87,8 +87,8 @@ appc.LCM.provider.pass=Kp8bJ4SXszM0WXlhak3eHlcse2gAw84vaoGGmJvUy2U
appc.LCM.provider.url=http://localhost:8181/restconf/operations/appc-provider-lcm
# properties from appc-netconf-adapter-bundle, appc-dg-common, appc-dmaap-adapter-bundle
-poolMembers=dmaap.{{.Values.nsPrefix}}:3904
-event.pool.members=dmaap.{{.Values.nsPrefix}}:3904
+poolMembers=dmaap.{{.Release.Namespace}}:3904
+event.pool.members=dmaap.{{.Release.Namespace}}:3904
restconf.user=admin
restconf.pass=Kp8bJ4SXszM0WXlhak3eHlcse2gAw84vaoGGmJvUy2U
@@ -106,7 +106,7 @@ test.url=http://api.appc.local/vm/9999999/test/99999999-9999-9999-9999-999999999
org.openecomp.appc.iaas.skiphypervisorcheck=true
# Properties from default.properties in the src/test and src/main paths of appc-asdc-listener-bundle
-appc.sdc.host=sdc-be.{{.Values.nsPrefix}}:8443
+appc.sdc.host=sdc-be.{{.Release.Namespace}}:8443
appc.sdc.env=APPC-ASDC-ENV
appc.sdc.user=test
appc.sdc.pass=test
@@ -118,12 +118,12 @@ appc.sdc.provider.url=http://localhost:8181/restconf/operations/AsdcMessage:conf
DCAE.dmaap.event.topic.write=EventSenderTest
DCAE.dmaap.appc.username=test
DCAE.dmaap.appc.password=test
-DCAE.dmaap.event.pool.members=dmaap.{{.Values.nsPrefix}}:3904
+DCAE.dmaap.event.pool.members=dmaap.{{.Release.Namespace}}:3904
#OAM Listener
appc.OAM.disabled=true
appc.OAM.provider.url=http://localhost:8181/restconf/operations/appc-oam
-appc.OAM.poolMembers=dmaap.{{.Values.nsPrefix}}:3904
+appc.OAM.poolMembers=dmaap.{{.Release.Namespace}}:3904
appc.OAM.service=ueb
appc.OAM.topic.read=testOAM
appc.OAM.topic.write=testOAM
diff --git a/kubernetes/appc/resources/config/appc/opt/openecomp/appc/data/properties/dblib.properties b/kubernetes/appc/resources/config/appc/opt/onap/appc/data/properties/dblib.properties
index 888ee9f0d9..17b7ffdfb0 100644
--- a/kubernetes/appc/resources/config/appc/opt/openecomp/appc/data/properties/dblib.properties
+++ b/kubernetes/appc/resources/config/appc/opt/onap/appc/data/properties/dblib.properties
@@ -22,7 +22,7 @@
org.onap.ccsdk.sli.dbtype=jdbc
org.onap.ccsdk.sli.jdbc.hosts=sdnctldb01
-org.onap.ccsdk.sli.jdbc.url=jdbc:mysql://appc-dbhost.{{.Values.nsPrefix}}:3306/sdnctl
+org.onap.ccsdk.sli.jdbc.url=jdbc:mysql://{{.Values.mysql.service.name}}.{{.Release.Namespace}}:3306/sdnctl
org.onap.ccsdk.sli.jdbc.driver=org.mariadb.jdbc.Driver
org.onap.ccsdk.sli.jdbc.database=sdnctl
org.onap.ccsdk.sli.jdbc.user=sdnctl
diff --git a/kubernetes/appc/resources/config/appc/opt/openecomp/appc/data/properties/svclogic.properties b/kubernetes/appc/resources/config/appc/opt/onap/appc/data/properties/svclogic.properties
index ea38616810..fd62b08b5f 100644
--- a/kubernetes/appc/resources/config/appc/opt/openecomp/appc/data/properties/svclogic.properties
+++ b/kubernetes/appc/resources/config/appc/opt/onap/appc/data/properties/svclogic.properties
@@ -20,7 +20,7 @@
org.onap.ccsdk.sli.dbtype = dblib
#Note : the next 4 fields are only used if org.onap.ccsdk.sli.dbtype = jdbc
-org.onap.ccsdk.sli.jdbc.url=jdbc:mysql://appc-dbhost.{{.Values.nsPrefix}}:3306/sdnctl
+org.onap.ccsdk.sli.jdbc.url=jdbc:mysql://{{.Values.mysql.service.name}}.{{.Release.Namespace}}:3306/sdnctl
org.onap.ccsdk.sli.jdbc.database=sdnctl
org.onap.ccsdk.sli.jdbc.user=sdnctl
org.onap.ccsdk.sli.jdbc.password=gamma
diff --git a/kubernetes/appc/resources/config/appc/opt/openecomp/appc/svclogic/bin/showActiveGraphs.sh b/kubernetes/appc/resources/config/appc/opt/onap/appc/svclogic/bin/showActiveGraphs.sh
index 5409d9e552..03ad425242 100755
--- a/kubernetes/appc/resources/config/appc/opt/openecomp/appc/svclogic/bin/showActiveGraphs.sh
+++ b/kubernetes/appc/resources/config/appc/opt/onap/appc/svclogic/bin/showActiveGraphs.sh
@@ -22,7 +22,7 @@
MYSQL_USER=${MYSQL_USER:-sdnctl}
MYSQL_PWD=${MYSQL_PWD:-gamma}
MYSQL_DB=${MYSQL_DB:-sdnctl}
-MYSQL_HOST=${MYSQL_HOST:-appc-dbhost.{{.Values.nsPrefix}}}
+MYSQL_HOST=${MYSQL_HOST:-{{.Values.mysql.service.name}}.{{.Release.Namespace}}}
mysql --user=${MYSQL_USER} --password=${MYSQL_PWD} --host=${MYSQL_HOST} ${MYSQL_DB} <<-END
SELECT module, rpc, version, mode from SVC_LOGIC where active='Y';
diff --git a/kubernetes/appc/resources/config/appc/opt/openecomp/appc/svclogic/config/svclogic.properties b/kubernetes/appc/resources/config/appc/opt/onap/appc/svclogic/config/svclogic.properties
index 2f67a5822f..bd581e0241 100644
--- a/kubernetes/appc/resources/config/appc/opt/openecomp/appc/svclogic/config/svclogic.properties
+++ b/kubernetes/appc/resources/config/appc/opt/onap/appc/svclogic/config/svclogic.properties
@@ -20,7 +20,7 @@
###
org.onap.ccsdk.sli.dbtype = jdbc
-org.onap.ccsdk.sli.jdbc.url = jdbc:mysql://appc-sdnctldb01.{{.Values.nsPrefix}}:3306/sdnctl
+org.onap.ccsdk.sli.jdbc.url = jdbc:mysql://{{.Values.mysql.service.name}}.{{.Release.Namespace}}:3306/sdnctl
org.onap.ccsdk.sli.jdbc.database = sdnctl
org.onap.ccsdk.sli.jdbc.user = sdnctl
org.onap.ccsdk.sli.jdbc.password = gamma
diff --git a/kubernetes/appc/resources/config/appc/opt/onap/sdnc/bin/installSdncDb.sh b/kubernetes/appc/resources/config/appc/opt/onap/sdnc/bin/installSdncDb.sh
index 75680bd942..25560fbef4 100755
--- a/kubernetes/appc/resources/config/appc/opt/onap/sdnc/bin/installSdncDb.sh
+++ b/kubernetes/appc/resources/config/appc/opt/onap/sdnc/bin/installSdncDb.sh
@@ -22,7 +22,7 @@
###
SDNC_HOME=${SDNC_HOME:-/opt/onap/sdnc}
-MYSQL_PASSWD=${MYSQL_PASSWD:-openECOMP1.0}
+MYSQL_PASSWD=${MYSQL_PASSWD:-{{.Values.config.dbRootPassword}}}
SDNC_DB_USER=${SDNC_DB_USER:-sdnctl}
SDNC_DB_PASSWD=${SDNC_DB_PASSWD:-gamma}
@@ -30,7 +30,7 @@ SDNC_DB_DATABASE=${SDN_DB_DATABASE:-sdnctl}
# Create tablespace and user account
-mysql -h appc-dbhost.{{.Values.nsPrefix}} -u root -p${MYSQL_PASSWD} mysql <<-END
+mysql -h {{.Values.mysql.service.name}}.{{.Release.Namespace}} -u root -p${MYSQL_PASSWD} mysql <<-END
CREATE DATABASE ${SDNC_DB_DATABASE};
CREATE USER '${SDNC_DB_USER}'@'localhost' IDENTIFIED BY '${SDNC_DB_PASSWD}';
CREATE USER '${SDNC_DB_USER}'@'%' IDENTIFIED BY '${SDNC_DB_PASSWD}';
@@ -41,6 +41,6 @@ END
if [ -f ${SDNC_HOME}/data/odlsli.dump ]
then
-mysql -h appc-dbhost.{{.Values.nsPrefix}} -u root -p${MYSQL_PASSWD} sdnctl < ${SDNC_HOME}/data/odlsli.dump
+mysql -h {{.Values.mysql.service.name}}.{{.Release.Namespace}} -u root -p${MYSQL_PASSWD} sdnctl < ${SDNC_HOME}/data/odlsli.dump
fi
diff --git a/kubernetes/appc/resources/config/appc/opt/onap/sdnc/bin/startODL.sh b/kubernetes/appc/resources/config/appc/opt/onap/sdnc/bin/startODL.sh
index 87c95ee3b3..a84893c00f 100755
--- a/kubernetes/appc/resources/config/appc/opt/onap/sdnc/bin/startODL.sh
+++ b/kubernetes/appc/resources/config/appc/opt/onap/sdnc/bin/startODL.sh
@@ -28,13 +28,13 @@ ODL_HOME=${ODL_HOME:-/opt/opendaylight/current}
ODL_ADMIN_PASSWORD=${ODL_ADMIN_PASSWORD:-Kp8bJ4SXszM0WXlhak3eHlcse2gAw84vaoGGmJvUy2U}
SDNC_HOME=${SDNC_HOME:-/opt/onap/sdnc}
SLEEP_TIME=${SLEEP_TIME:-120}
-MYSQL_PASSWD=${MYSQL_PASSWD:-openECOMP1.0}
+MYSQL_PASSWD=${MYSQL_PASSWD:-{{.Values.config.dbRootPassword}}}
#
# Wait for database
#
echo "Waiting for mysql"
-until mysql -h appc-dbhost.{{.Values.nsPrefix}} -u root -p${MYSQL_PASSWD} mysql &> /dev/null
+until mysql -h {{.Values.mysql.service.name}}.{{.Release.Namespace}} -u root -p{{.Values.config.dbRootPassword}} mysql &> /dev/null
do
printf "."
sleep 1
diff --git a/kubernetes/appc/resources/config/appc/opt/onap/sdnc/data/properties/aaiclient.properties b/kubernetes/appc/resources/config/appc/opt/onap/sdnc/data/properties/aaiclient.properties
index 9e29744bb3..b2f7102d8c 100644
--- a/kubernetes/appc/resources/config/appc/opt/onap/sdnc/data/properties/aaiclient.properties
+++ b/kubernetes/appc/resources/config/appc/opt/onap/sdnc/data/properties/aaiclient.properties
@@ -39,7 +39,7 @@ org.onap.ccsdk.sli.adaptors.aai.application=openECOMP
#
# Configuration file for A&AI Client
#
-org.onap.ccsdk.sli.adaptors.aai.uri=https://aai-service.{{.Values.nsPrefix}}:8443
+org.onap.ccsdk.sli.adaptors.aai.uri=https://aai-service.{{.Release.Namespace}}:8443
# query
@@ -133,8 +133,8 @@ org.onap.ccsdk.sli.adaptors.aai.path.vnf.image.query=/aai/v11/service-design-and
# UBB Notify
org.onap.ccsdk.sli.adaptors.aai.path.notify=/aai/v11/actions/notify
-org.onap.ccsdk.sli.adaptors.aai.notify.selflink.fqdn=https://aai-service.{{.Values.nsPrefix}}:8443/restconf/config/L3SDN-API:services/layer3-service-list/{service-instance-id}
-org.onap.ccsdk.sli.adaptors.aai.notify.selflink.avpn=https://aai-service.{{.Values.nsPrefix}}:8443/restconf/config/L3AVPN-EVC-API:services/service-list/{service-instance-id}/service-data/avpn-logicalchannel-information
+org.onap.ccsdk.sli.adaptors.aai.notify.selflink.fqdn=https://aai-service.{{.Release.Namespace}}:8443/restconf/config/L3SDN-API:services/layer3-service-list/{service-instance-id}
+org.onap.ccsdk.sli.adaptors.aai.notify.selflink.avpn=https://aai-service.{{.Release.Namespace}}:8443/restconf/config/L3AVPN-EVC-API:services/service-list/{service-instance-id}/service-data/avpn-logicalchannel-information
# Service
org.onap.ccsdk.sli.adaptors.aai.path.service=/aai/v11/service-design-and-creation/services/service/{service-id}
diff --git a/kubernetes/appc/resources/config/appc/opt/onap/sdnc/data/properties/dblib.properties b/kubernetes/appc/resources/config/appc/opt/onap/sdnc/data/properties/dblib.properties
index 6107a80416..f603977013 100644
--- a/kubernetes/appc/resources/config/appc/opt/onap/sdnc/data/properties/dblib.properties
+++ b/kubernetes/appc/resources/config/appc/opt/onap/sdnc/data/properties/dblib.properties
@@ -23,7 +23,7 @@
org.onap.ccsdk.sli.dbtype=jdbc
org.onap.ccsdk.sli.jdbc.hosts=sdnctldb01
-org.onap.ccsdk.sli.jdbc.url=jdbc:mysql://appc-dbhost.{{.Values.nsPrefix}}:3306/sdnctl
+org.onap.ccsdk.sli.jdbc.url=jdbc:mysql://{{.Values.mysql.service.name}}.{{.Release.Namespace}}:3306/sdnctl
org.onap.ccsdk.sli.jdbc.driver=org.mariadb.jdbc.Driver
org.onap.ccsdk.sli.jdbc.database=sdnctl
org.onap.ccsdk.sli.jdbc.user=sdnctl
diff --git a/kubernetes/appc/resources/config/appc/opt/onap/sdnc/data/properties/svclogic.properties b/kubernetes/appc/resources/config/appc/opt/onap/sdnc/data/properties/svclogic.properties
index 2954bb00a5..908d60a089 100644
--- a/kubernetes/appc/resources/config/appc/opt/onap/sdnc/data/properties/svclogic.properties
+++ b/kubernetes/appc/resources/config/appc/opt/onap/sdnc/data/properties/svclogic.properties
@@ -21,7 +21,7 @@
org.onap.ccsdk.sli.dbtype = dblib
#Note : the next 4 fields are only used if org.onap.ccsdk.sli.dbtype = jdbc
-org.onap.ccsdk.sli.jdbc.url=jdbc:mysql://appc-dbhost.{{.Values.nsPrefix}}:3306/sdnctl
+org.onap.ccsdk.sli.jdbc.url=jdbc:mysql://{{.Values.mysql.service.name}}.{{.Release.Namespace}}:3306/sdnctl
org.onap.ccsdk.sli.jdbc.database=sdnctl
org.onap.ccsdk.sli.jdbc.user=sdnctl
org.onap.ccsdk.sli.jdbc.password=gamma
diff --git a/kubernetes/appc/resources/config/appc/opt/onap/sdnc/svclogic/bin/showActiveGraphs.sh b/kubernetes/appc/resources/config/appc/opt/onap/sdnc/svclogic/bin/showActiveGraphs.sh
index ceeea5914f..a568dfdc20 100755
--- a/kubernetes/appc/resources/config/appc/opt/onap/sdnc/svclogic/bin/showActiveGraphs.sh
+++ b/kubernetes/appc/resources/config/appc/opt/onap/sdnc/svclogic/bin/showActiveGraphs.sh
@@ -22,7 +22,7 @@
MYSQL_USER=${MYSQL_USER:-sdnctl}
MYSQL_PWD=${MYSQL_PWD:-gamma}
MYSQL_DB=${MYSQL_DB:-sdnctl}
-MYSQL_HOST=${MYSQL_HOST:-appc-dbhost.{{.Values.nsPrefix}}}
+MYSQL_HOST=${MYSQL_HOST:-{{.Values.mysql.service.name}}.{{.Release.Namespace}}}
mysql --user=${MYSQL_USER} --password=${MYSQL_PWD} --host=${MYSQL_HOST} ${MYSQL_DB} <<-END
SELECT module, rpc, version, mode from SVC_LOGIC where active='Y';
diff --git a/kubernetes/appc/resources/config/appc/opt/onap/sdnc/svclogic/config/svclogic.properties b/kubernetes/appc/resources/config/appc/opt/onap/sdnc/svclogic/config/svclogic.properties
index bcf321c947..44ae32f9cc 100644
--- a/kubernetes/appc/resources/config/appc/opt/onap/sdnc/svclogic/config/svclogic.properties
+++ b/kubernetes/appc/resources/config/appc/opt/onap/sdnc/svclogic/config/svclogic.properties
@@ -20,7 +20,7 @@
###
org.onap.ccsdk.sli.dbtype = jdbc
-org.onap.ccsdk.sli.jdbc.url = jdbc:mysql://appc-sdnctldb01.{{.Values.nsPrefix}}:3306/sdnctl
+org.onap.ccsdk.sli.jdbc.url = jdbc:mysql://{{.Values.mysql.service.name}}.{{.Release.Namespace}}:3306/sdnctl
org.onap.ccsdk.sli.jdbc.database = sdnctl
org.onap.ccsdk.sli.jdbc.user = sdnctl
org.onap.ccsdk.sli.jdbc.password = gamma
diff --git a/kubernetes/appc/resources/config/dgbuilder/svclogic.properties b/kubernetes/appc/resources/config/dgbuilder/svclogic.properties
deleted file mode 100644
index 8b0723b72b..0000000000
--- a/kubernetes/appc/resources/config/dgbuilder/svclogic.properties
+++ /dev/null
@@ -1,5 +0,0 @@
-org.onap.ccsdk.sli.dbtype=jdbc
-org.onap.ccsdk.sli.jdbc.url=jdbc:mysql://appc-dbhost.{{.Values.nsPrefix}}:3306/sdnctl
-org.onap.ccsdk.sli.jdbc.database=sdnctl
-org.onap.ccsdk.sli.jdbc.user=sdnctl
-org.onap.ccsdk.sli.jdbc.password=gamma
diff --git a/kubernetes/appc/resources/config/log/filebeat/log4j/filebeat.yml b/kubernetes/appc/resources/config/log/filebeat/log4j/filebeat.yml
index 2cd63e1d98..52161aafad 100644
--- a/kubernetes/appc/resources/config/log/filebeat/log4j/filebeat.yml
+++ b/kubernetes/appc/resources/config/log/filebeat/log4j/filebeat.yml
@@ -29,7 +29,7 @@ output.logstash:
#List of logstash server ip addresses with port number.
#But, in our case, this will be the loadbalancer IP address.
#For the below property to work the loadbalancer or logstash should expose 5044 port to listen the filebeat events or port in the property should be changed appropriately.
- hosts: ["logstash.{{.Values.nsPrefix}}:5044"]
+ hosts: ["logstash.{{.Release.Namespace}}:5044"]
#If enable will do load balancing among availabe Logstash, automatically.
loadbalance: true
diff --git a/kubernetes/appc/resources/scripts/dgbuilder/createReleaseDir.sh b/kubernetes/appc/resources/scripts/dgbuilder/createReleaseDir.sh
deleted file mode 100755
index d63687a644..0000000000
--- a/kubernetes/appc/resources/scripts/dgbuilder/createReleaseDir.sh
+++ /dev/null
@@ -1,129 +0,0 @@
-#!/bin/bash
-export PATH=$PATH:.
-appDir=$(pwd)
-if [ "$#" != 3 -a "$#" != 4 ]
-then
- echo "Usage $0 releaseDir loginId emailAddress [gitLocalRepository]"
- echo "Note: Specify the gitLocalRepository path if you would want to be able to import flows from your local git repository"
- exit
-fi
-if [ ! -e "releases" ]
-then
- mkdir releases
-fi
-releaseDir="$1"
-name="Release $releaseDir"
-loginId="$2"
-emailid="$3"
-dbHost="appc-dbhost.{{.Values.nsPrefix}}"
-dbPort="3306"
-dbName="sdnctl"
-dbUser="sdnctl"
-dbPassword="gamma"
-gitLocalRepository="$4"
-
-lastPort=$(find "releases/" -name "customSettings.js" |xargs grep uiPort|cut -d: -f2|sed -e s/,//|sort|tail -1)
-echo $lastPort|grep uiPort >/dev/null 2>&1
-if [ "$?" == "0" ]
-then
-lastPort=$(find "releases/" -name "customSettings.js" |xargs grep uiPort|cut -d: -f3|sed -e s/,//|sort|tail -1)
-fi
-#echo $lastPort
-if [ "${lastPort}" == "" ]
-then
- lastPort="3099"
-fi
-let nextPort=$(expr $lastPort+1)
-#echo $nextPort
-if [ ! -e "releases/$releaseDir" ]
-then
-mkdir releases/$releaseDir
-cd releases/$releaseDir
-mkdir flows
-mkdir flows/shared
-mkdir flows/shared/backups
-mkdir html
-mkdir xml
-mkdir lib
-mkdir lib/flows
-mkdir logs
-mkdir conf
-mkdir codecloud
-customSettingsFile="customSettings.js"
-if [ ! -e "./$customSettingsFile" ]
-then
- echo "module.exports = {" >$customSettingsFile
- echo " 'name' : '$name'," >>$customSettingsFile
- echo " 'emailAddress' :'$emailid'," >>$customSettingsFile
- echo " 'uiPort' :$nextPort," >>$customSettingsFile
- echo " 'mqttReconnectTime': 15000," >>$customSettingsFile
- echo " 'serialReconnectTime' : 15000," >>$customSettingsFile
- echo " 'debugMaxLength': 1000," >>$customSettingsFile
- echo " 'htmlPath': 'releases/$releaseDir/html/'," >>$customSettingsFile
- echo " 'xmlPath': 'releases/$releaseDir/xml/'," >>$customSettingsFile
- echo " 'flowFile' : 'releases/$releaseDir/flows/flows.json'," >>$customSettingsFile
- echo " 'sharedDir': 'releases/$releaseDir/flows/shared'," >>$customSettingsFile
- echo " 'userDir' : 'releases/$releaseDir'," >>$customSettingsFile
- echo " 'httpAuth': {user:'$loginId',pass:'cc03e747a6afbbcbf8be7668acfebee5'}," >>$customSettingsFile
- echo " 'dbHost': '$dbHost'," >>$customSettingsFile
- echo " 'dbPort': '$dbPort'," >>$customSettingsFile
- echo " 'dbName': '$dbName'," >>$customSettingsFile
- echo " 'dbUser': '$dbUser'," >>$customSettingsFile
- echo " 'dbPassword': '$dbPassword'," >>$customSettingsFile
- echo " 'gitLocalRepository': '$gitLocalRepository'" >>$customSettingsFile
- echo " }" >>$customSettingsFile
-fi
- #echo "Created custom settings file $customSettingsFile"
- echo "Done ....."
-else
- echo "ERROR:customSettings file $customSettingsFile already exists for $releaseDir"
- exit
-fi
-#echo "Content of custom settings file"
-#echo "============================================================================"
-# cat $customSettingsFile
-#echo "============================================================================"
-svclogicPropFile="./conf/svclogic.properties"
-if [ ! -d "${appDir}/yangFiles" ]
-then
- mkdir -p "${appDir}/yangFiles"
-fi
-if [ ! -d "${appDir}/generatedJS" ]
-then
- mkdir -p "${appDir}/generatedJS"
-fi
-
-if [ ! -e "./$svclogicPropFile" ]
-then
- echo "org.onap.ccsdk.sli.dbtype=jdbc" >$svclogicPropFile
- echo "org.onap.ccsdk.sli.jdbc.url=jdbc:mysql://appc-dbhost.{{.Values.nsPrefix}}:3306/sdnctl" >>$svclogicPropFile
- echo "org.onap.ccsdk.sli.jdbc.database=sdnctl" >>$svclogicPropFile
- echo "org.onap.ccsdk.sli.jdbc.user=sdnctl" >>$svclogicPropFile
- echo "org.onap.ccsdk.sli.jdbc.password=gamma" >>$svclogicPropFile
-fi
-if [ ! -e "${appDir}/flowShareUsers.js" ]
-then
- echo "module.exports = {\"flowShareUsers\":" >${appDir}/flowShareUsers.js
- echo " [" >>${appDir}/flowShareUsers.js
- echo " ]" >>${appDir}/flowShareUsers.js
- echo "}" >>${appDir}/flowShareUsers.js
-fi
-grep "$releaseDir" ${appDir}/flowShareUsers.js >/dev/null 2>&1
-if [ "$?" != "0" ]
-then
- num_of_lines=$(cat ${appDir}/flowShareUsers.js|wc -l)
- if [ $num_of_lines -gt 4 ]
- then
- content=$(head -n -2 ${appDir}/flowShareUsers.js)
- echo "${content}," > ${appDir}/flowShareUsers.js
- else
- content=$(head -n -2 ${appDir}/flowShareUsers.js)
- echo "$content" > ${appDir}/flowShareUsers.js
- fi
- echo " {" >> ${appDir}/flowShareUsers.js
- echo " \"name\" : \"$name\"," >> ${appDir}/flowShareUsers.js
- echo " \"rootDir\" : \"$releaseDir\"" >> ${appDir}/flowShareUsers.js
- echo " }" >> ${appDir}/flowShareUsers.js
- echo " ]" >> ${appDir}/flowShareUsers.js
- echo "}" >> ${appDir}/flowShareUsers.js
-fi
diff --git a/kubernetes/appc/resources/scripts/dgbuilder/customSettings.js b/kubernetes/appc/resources/scripts/dgbuilder/customSettings.js
deleted file mode 100644
index 40a624d44d..0000000000
--- a/kubernetes/appc/resources/scripts/dgbuilder/customSettings.js
+++ /dev/null
@@ -1,38 +0,0 @@
-module.exports={
- "name": "Release sdnc1.0",
- "emailAddress": "dguser@onap.org",
- "uiPort": 3100,
- "mqttReconnectTime": 15000,
- "serialReconnectTime": 15000,
- "debugMaxLength": 1000,
- "htmlPath": "releases/sdnc1.0/html/",
- "xmlPath": "releases/sdnc1.0/xml/",
- "flowFile": "releases/sdnc1.0/flows/flows.json",
- "sharedDir": "releases/sdnc1.0/flows/shared",
- "userDir": "releases/sdnc1.0",
- "httpAuth": {
- "user": "dguser",
- "pass": "cc03e747a6afbbcbf8be7668acfebee5"
- },
- "dbHost": "appc-dbhost.{{.Values.nsPrefix}}",
- "dbPort": "3306",
- "dbName": "sdnctl",
- "dbUser": "sdnctl",
- "dbPassword": "gamma",
- "gitLocalRepository": "",
- "httpRoot": "/",
- "disableEditor": false,
- "httpAdminRoot": "/",
- "httpAdminAuth": {
- "user": "dguser",
- "pass": "cc03e747a6afbbcbf8be7668acfebee5"
- },
- "httpNodeRoot": "/",
- "httpNodeAuth": {
- "user": "dguser",
- "pass": "cc03e747a6afbbcbf8be7668acfebee5"
- },
- "uiHost": "0.0.0.0",
- "version": "0.9.1",
- "performGitPull": "N"
-}