summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Mokry <michael.mokry@att.com>2019-04-11 06:07:17 -0500
committerMichael Mokry <michael.mokry@att.com>2019-04-11 06:07:17 -0500
commit74ff8601429337ca0b0ad9039188bb09a5d4a640 (patch)
tree7b1d70005b8a312a67e9c44f061ac5389f847f56
parentbfb8d12818346b96c9ab918e72327e1d13662321 (diff)
Fix the xacml-pdp CSIT failures
Looks like CSIT uses docker to install xacml-pdp so a change in OOM is not necessary to fix this problem. I took a look at the PAP script and found some small differenences and made those changes in xacml-pdp. I have not been able to successfully test this as I spent all night trying to figure out how to execute it in my VM with and without arguments. I added some debugger code in as well to get more information in the logs and see if the property file is actually being found. Change-Id: Ib6ca95edab4483aa4e65efca73a9f58342cc1ec0 Issue-ID: POLICY-1449 Signed-off-by: Michael Mokry <michael.mokry@att.com>
-rw-r--r--packages/policy-xacmlpdp-docker/src/main/docker/policy-pdpx.sh11
1 files changed, 8 insertions, 3 deletions
diff --git a/packages/policy-xacmlpdp-docker/src/main/docker/policy-pdpx.sh b/packages/policy-xacmlpdp-docker/src/main/docker/policy-pdpx.sh
index 7e0eb112..45ba314d 100644
--- a/packages/policy-xacmlpdp-docker/src/main/docker/policy-pdpx.sh
+++ b/packages/policy-xacmlpdp-docker/src/main/docker/policy-pdpx.sh
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/bin/bash -xv
#
# ============LICENSE_START=======================================================
# Copyright (C) 2019 AT&T Intellectual Property. All rights reserved.
@@ -18,7 +18,6 @@
# SPDX-License-Identifier: Apache-2.0
# ============LICENSE_END=========================================================
#
-
JAVA_HOME=/usr/lib/jvm/java-1.8-openjdk/
POLICY_PDPX_HOME=/opt/app/policy/pdpx
KEYSTORE="${POLICY_HOME}/etc/ssl/policy-keystore"
@@ -27,12 +26,17 @@ TRUSTSTORE="${POLICY_HOME}/etc/ssl/policy-truststore"
TRUSTSTORE_PASSWD="Pol1cy_0nap"
-if [ "$#" -eq 1 ]; then
+if [ "$#" -ge 1 ]; then
CONFIG_FILE=$1
else
CONFIG_FILE=${CONFIG_FILE}
fi
+if [ "$#" -ge 2 ]; then
+ PROP_FILE=$2
+else
+ PROP_FILE=${PROP_FILE}
+
if [ -z "$CONFIG_FILE" ]
then
CONFIG_FILE="$POLICY_PDPX_HOME/etc/defaultConfig.json"
@@ -44,5 +48,6 @@ if [ -z "$PROP_FILE" ]
fi
echo "Policy Xacml PDP config file: $CONFIG_FILE"
+echo "Policy Xacml PDP topic properties file: $PROP_FILE"
$JAVA_HOME/bin/java -cp "$POLICY_PDPX_HOME/etc:$POLICY_PDPX_HOME/lib/*" -Djavax.net.ssl.keyStore="$KEYSTORE" -Djavax.net.ssl.keyStorePassword="$KEYSTORE_PASSWD" -Djavax.net.ssl.trustStore="$TRUSTSTORE" -Djavax.net.ssl.trustStorePassword="$TRUSTSTORE_PASSWD" org.onap.policy.pdpx.main.startstop.Main -c $CONFIG_FILE -p $PROP_FILE