Policy 1707 Docker script changes 39/4039/1
authorITSERVICES\rb7147 <rb7147@att.com>
Tue, 9 May 2017 17:54:45 +0000 (13:54 -0400)
committerITSERVICES\rb7147 <rb7147@att.com>
Tue, 9 May 2017 19:23:41 +0000 (15:23 -0400)
Change-Id: I765e2badf48d4f7554de2a6ea037289e3f76e512
Signed-off-by: ITSERVICES\rb7147 <rb7147@att.com>
config/pe/base.conf
config/pe/brmsgw.conf
config/pe/console.conf
config/pe/pap-tweaks.sh
config/pe/pdp.conf
config/pe/push-policies.sh
config/pe/pypdp-tweaks.sh [deleted file]
config/pe/pypdp.conf [deleted file]
docker-compose.yml
policy-pe/do-start.sh
policy-pe/docker-install.sh

index e798a40..fc1718f 100644 (file)
@@ -1,6 +1,8 @@
 JAVA_HOME=/usr/lib/jvm/java-8-openjdk-amd64
 POLICY_HOME=/opt/app/policy
 KEYSTORE_PASSWD=PolicyR0ck$
+KEY_PASSWD=PolicyR0ck$
+TRUSTSTORE_PASSWD=PolicyR0ck$
 
 JDBC_DRIVER=org.mariadb.jdbc.Driver
 JDBC_URL=jdbc:mariadb://mariadb:3306/ecomp_sdk
@@ -18,3 +20,7 @@ test_via_jmx=false
 jmx_fqdn=
 
 ENVIRONMENT=TEST
+
+#Micro Service Model Properties
+policy_msEcompName=
+policy_msPolicyName=
\ No newline at end of file
index da2cd0a..f918847 100644 (file)
@@ -41,3 +41,14 @@ node_type=brms_gateway
 CLIENT_ID=PyPDPServer
 CLIENT_KEY=test
 ENVIRONMENT=TEST
+
+#Notification Properties... type can be either websocket, ueb, or dmaap
+BRMS_NOTIFICATION_TYPE=websocket
+BRMS_UEB_URL=
+BRMS_UEB_TOPIC=
+BRMS_UEB_DELAY=
+BRMS_CLIENT_ID=
+BRMS_CLIENT_KEY=
+BRMS_UEB_API_KEY=
+BRMS_UEB_API_SECRET=
+
index 6606add..8523307 100644 (file)
@@ -116,6 +116,7 @@ ecomp_smtp_host=
 ecomp_smtp_port=25
 ecomp_smtp_userName=
 ecomp_smtp_password=
+ecomp_smtp_emailExtension=
 ecomp_application_name=
 
 #-----------------------ECOMP-PORTAL-Properties----------------------
@@ -129,7 +130,3 @@ ECOMP_UEB_APP_SECRET=
 ECOMP_UEB_APP_MAILBOX_NAME=
 APP_DISPLAY_NAME=OpenECOMP Policy
 ECOMP_SHARED_CONTEXT_REST_URL=http://portal.api.simpledemo.openecomp.org:8989/ECOMPPORTAL/context
-
-#Add the Rest PAP url and pap auth password on adding delimiter @Auth@ 
-
-REST_PAPURL_WITH_AUTH_PASSWORD=http://policy.api.simpledemo.openecomp.org:9091/pap/@Auth@dGVzdHBhcDphbHBoYTEyMw==
index be8a905..36ac368 100755 (executable)
@@ -1,15 +1 @@
 #! /bin/bash
-
-# config directory may contain an ip_addr.txt file that specifies
-# the VM IP address.  Substitute this value in the URL in the
-# config.json file, overriding the hostname that came from the
-# REST_PAPURL_WITH_AUTH_PASSWORD property in console.conf. This is
-# to avoid hardcoding an IP address in console.conf that can change
-# from one VM instance to the next.
-
-if [[ -f config/ip_addr.txt ]]; then
-       vm_ip=$(<config/ip_addr.txt)
-       echo "Substituting VM IP address $vm_ip in console config.json file"
-       sed -i -e "s@http:.*:@http://$vm_ip:@" \
-         $POLICY_HOME/servers/console/webapps/ecomp/app/policyApp/Properties/config.json
-fi
index 363fdcb..7248717 100644 (file)
@@ -34,3 +34,20 @@ node_type=pdp_xacml
 resource_name=pdp_1
 dependency_groups=pdplp_1;pypdp_1;brmsgw_1
 test_via_jmx=true
+
+#
+# Notification Properties
+# Notifcation type: websocket, ueb or dmaap... if left blank websocket is the default
+PDP_NOTIFICATION_TYPE=websocket,UEB
+PDP_UEB_CLUSTER=
+PDP_UEB_TOPIC=
+PDP_UEB_DELAY=
+PDP_UEB_API_KEY=
+PDP_UEB_API_SECRET=
+PDP_DMAAP_AAF_LOGIN=
+PDP_DMAAP_AAF_PASSWORD=
+
+#AAF Policy Name space
+#Required only, when we use AAF
+POLICY_AAF_NAMESPACE=
+POLICY_AAF_RESOURCE=
\ No newline at end of file
index 957156e..414e2e5 100644 (file)
@@ -12,7 +12,7 @@ curl -X PUT --header 'Content-Type: application/json' --header 'Accept: text/pla
   "policyName": "vFirewall",
   "policyScope": "com",
   "policyType": "MicroService"
-}' 'http://pypdp:8480/PyPDPServer/pushPolicy'
+}' 'http://pdp:8081/pdp/api/pushPolicy'
 
 sleep 2
 
@@ -21,7 +21,7 @@ curl -X PUT --header 'Content-Type: application/json' --header 'Accept: text/pla
   "policyName": "vLoadBalancer",
   "policyScope": "com",
   "policyType": "MicroService"
-}' 'http://pypdp:8480/PyPDPServer/pushPolicy' 
+}' 'http://pdp:8081/pdp/api/pushPolicy' 
 
 sleep 2
 curl -X PUT --header 'Content-Type: application/json' --header 'Accept: text/plain' --header 'ClientAuth: cHl0aG9uOnRlc3Q=' --header 'Authorization: Basic dGVzdHJlc3Q6M2MwbXBVI2gwMUBOMWMz' --header 'Environment: TEST' -d '{
@@ -29,7 +29,7 @@ curl -X PUT --header 'Content-Type: application/json' --header 'Accept: text/pla
   "policyName": "BRMSParamvLBDemoPolicy",
   "policyScope": "com",
   "policyType": "BRMS_Param"
-}' 'http://pypdp:8480/PyPDPServer/pushPolicy'
+}' 'http://pdp:8081/pdp/api/pushPolicy'
 
 sleep 2
 
@@ -38,7 +38,7 @@ curl -X PUT --header 'Content-Type: application/json' --header 'Accept: text/pla
   "policyName": "BRMSParamvFWDemoPolicy",
   "policyScope": "com",
   "policyType": "BRMS_Param"
-}' 'http://pypdp:8480/PyPDPServer/pushPolicy'
+}' 'http://pdp:8081/pdp/api/pushPolicy'
 
 sleep 2
 
@@ -46,7 +46,7 @@ curl -X DELETE --header 'Content-Type: application/json' --header 'Accept: text/
 "pdpGroup": "default",
 "policyComponent": "PDP",
 "policyName": "com.Config_BRMS_Param_BRMSParamvFWDemoPolicy.1.xml"
-}' 'http://pypdp:8480/PyPDPServer/deletePolicy'
+}' 'http://pdp:8081/pdp/api/deletePolicy'
 
 
 
@@ -54,7 +54,7 @@ curl -X DELETE --header 'Content-Type: application/json' --header 'Accept: text/
 "pdpGroup": "default",
 "policyComponent": "PDP",
 "policyName": "com.Config_BRMS_Param_BRMSParamvLBDemoPolicy.1.xml"
-}' 'http://pypdp:8480/PyPDPServer/deletePolicy'
+}' 'http://pdp:8081/pdp/api/deletePolicy'
 
 sleep 2
 curl -X PUT --header 'Content-Type: application/json' --header 'Accept: text/plain' --header 'ClientAuth: cHl0aG9uOnRlc3Q=' --header 'Authorization: Basic dGVzdHJlc3Q6M2MwbXBVI2gwMUBOMWMz' --header 'Environment: TEST' -d '{
@@ -62,7 +62,7 @@ curl -X PUT --header 'Content-Type: application/json' --header 'Accept: text/pla
   "policyName": "BRMSParamvLBDemoPolicy",
   "policyScope": "com",
   "policyType": "BRMS_Param"
-}' 'http://pypdp:8480/PyPDPServer/pushPolicy'
+}' 'http://pdp:8081/pdp/api/pushPolicy'
 
 sleep 2
 
@@ -71,5 +71,5 @@ curl -X PUT --header 'Content-Type: application/json' --header 'Accept: text/pla
   "policyName": "BRMSParamvFWDemoPolicy",
   "policyScope": "com",
   "policyType": "BRMS_Param"
-}' 'http://pypdp:8480/PyPDPServer/pushPolicy'
+}' 'http://pdp:8081/pdp/api/pushPolicy'
 
diff --git a/config/pe/pypdp-tweaks.sh b/config/pe/pypdp-tweaks.sh
deleted file mode 100755 (executable)
index 5d899bd..0000000
+++ /dev/null
@@ -1,3 +0,0 @@
-#! /bin/bash
-
-
diff --git a/config/pe/pypdp.conf b/config/pe/pypdp.conf
deleted file mode 100644 (file)
index 4a792b4..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-# pypdp component installation configuration parameters
-
-# tomcat specific parameters
-
-TOMCAT_JMX_PORT=9994
-TOMCAT_SHUTDOWN_PORT=8405
-SSL_HTTP_CONNECTOR_PORT=8480
-SSL_AJP_CONNECTOR_PORT=8384
-SSL_AJP_CONNECTOR_REDIRECT_PORT=8443
-
-TOMCAT_X_MS_MB=1024
-TOMCAT_X_MX_MB=1024
-
-# pypdp parameters
-
-PDP_URL=http://pdp:8081/pdp/,testpdp,alpha123
-PAP_URL=http://pap:9091/pap/,testpap,alpha123
-PYPDP_ID=testrest
-PYPDP_PASSWORD=3c0mpU#h01@N1c3
-
-node_type=pypdp
-# the java property is RESOURCE_NAME (uppercase), but the conf parameter is lowercase
-resource_name=pypdp_1
-
-CLIENT_FILE=client.properties
index 699bf0d..242409f 100644 (file)
@@ -33,17 +33,6 @@ services:
       command: pdp
       volumes:
        - ./config/pe:/tmp/policy-install/config
-   pypdp:
-      image: onap/policy/policy-pe
-      container_name: pypdp
-      depends_on: 
-       - pap
-      hostname: pypdp
-      ports:
-       - "8480:8480"
-      command: pypdp
-      volumes:
-       - ./config/pe:/tmp/policy-install/config
    brmsgw:
       image: onap/policy/policy-pe
       container_name: brmsgw
index 8bdb8bc..fc02b86 100644 (file)
@@ -14,14 +14,11 @@ pap)
 pdp)
        comps="base pdp pdplp"
        ;;
-pypdp)
-       comps="base pypdp"
-       ;;
 brmsgw)
        comps="base brmsgw"
        ;;
 *)
-       echo "Usage: do-start.sh pap|pdp|pypdp|brmsgw" >&2
+       echo "Usage: do-start.sh pap|pdp|brmsgw" >&2
        exit 1
 esac
 
@@ -80,12 +77,11 @@ fi
 
 policy.sh start
 
-# on pap, wait for pap, pdp, pypdp, brmsgw, and nexus up,
+# on pap, wait for pap, pdp, brmsgw, and nexus up,
 # then push the initial default policies
 if [[ $container == pap ]]; then
        ./wait-for-port.sh pap 9091
        ./wait-for-port.sh pdp 8081
-       ./wait-for-port.sh pypdp 8480
        # brmsgw doesn't have a REST API, so check for JMX port instead
        ./wait-for-port.sh brmsgw 9989
        ./wait-for-port.sh nexus 8081
index d85e359..140947d 100644 (file)
@@ -9,8 +9,8 @@
 function usage() {
        echo -n "syntax: $(basename $0) "
        echo -n "--debug ("
-       echo -n "[--install base|pap|pdp|pypdp|console|mysql|brmsgw|paplp|pdplp] | "
-       echo -n "[--configure base|pap|pdp|pypdp|console|mysql|brmsgw|paplp|pdplp] | "
+       echo -n "[--install base|pap|pdp|console|mysql|brmsgw|paplp|pdplp] | "
+       echo -n "[--configure base|pap|pdp|console|mysql|brmsgw|paplp|pdplp] | "
 }
 
 function check_java() {
@@ -550,7 +550,7 @@ case $COMPONENT_TYPE in
        paplp)  ;;
        pdplp)  ;;
        skip)   ;;
-       *)              echo "invalid component type (${COMPONENT_TYPE}): must be in {base|pypdp|pdp|pap|console|mysql|brmsgw|paplp|pdplp}";
+       *)              echo "invalid component type (${COMPONENT_TYPE}): must be in {base|pdp|pap|console|mysql|brmsgw|paplp|pdplp}";
                        usage
                        exit 1
                        ;;
@@ -603,9 +603,6 @@ if [[ ${OPERATION} == install ]]; then
                base)   
                        install_base
                        ;;
-               pypdp)
-                       install_tomcat_component
-                       ;;
                pdp)    
                        install_tomcat_component
                        ;;
@@ -625,7 +622,7 @@ if [[ ${OPERATION} == install ]]; then
                        install_logparser
                        ;;
                *)              
-                       echo "invalid component type (${COMPONENT_TYPE}): must be in {base|pypdp|pdp|pap|console|mysql|brmsgw|paplp|pdplp}";
+                       echo "invalid component type (${COMPONENT_TYPE}): must be in {base|pdp|pap|console|mysql|brmsgw|paplp|pdplp}";
                        usage
                        exit 1
                        ;;
@@ -640,9 +637,6 @@ if [[ ${OPERATION} == configure ]]; then
                        configure_base
                        component_preconfigure
                        ;;
-               pypdp)
-                       configure_component "${COMPONENT_TYPE}.conf" "${POLICY_HOME}/servers/${COMPONENT_TYPE}/"
-                       ;;
                pdp)    
                        configure_component "${COMPONENT_TYPE}.conf" "${POLICY_HOME}/servers/${COMPONENT_TYPE}/"
                        ;;
@@ -662,7 +656,7 @@ if [[ ${OPERATION} == configure ]]; then
                        configure_component "${COMPONENT_TYPE}.conf" "${POLICY_HOME}/servers/${COMPONENT_TYPE}/"
                        ;;
                *)              
-                       echo "invalid component type (${COMPONENT_TYPE}): must be in {base|pypdp|pdp|pap|console|mysql|brmsgw|paplp|pdplp}";
+                       echo "invalid component type (${COMPONENT_TYPE}): must be in {base|pdp|pap|console|mysql|brmsgw|paplp|pdplp}";
                        usage
                        exit 1
                        ;;