summaryrefslogtreecommitdiffstats
path: root/packages/policy-xacmlpdp-docker/src/main/docker/policy-pdpx.sh
diff options
context:
space:
mode:
authorLiam Fallon <liam.fallon@est.tech>2022-09-02 09:50:06 +0000
committerGerrit Code Review <gerrit@onap.org>2022-09-02 09:50:06 +0000
commitfb61d6324218d19e00613093d2d96f2582dc2ac4 (patch)
treec6fe295624d1acb2e387b2c6216a13e8c886f81d /packages/policy-xacmlpdp-docker/src/main/docker/policy-pdpx.sh
parent9fa2252d7de9371202950b90820a2a2c437b68a4 (diff)
parent545f221f4e4f734767d8b467d27a6ef67bd99720 (diff)
Merge "Compatibility with mariadb 10.x and mysql 8.x"
Diffstat (limited to 'packages/policy-xacmlpdp-docker/src/main/docker/policy-pdpx.sh')
-rw-r--r--packages/policy-xacmlpdp-docker/src/main/docker/policy-pdpx.sh14
1 files changed, 13 insertions, 1 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 ffe6c44a..0c7b98b4 100644
--- a/packages/policy-xacmlpdp-docker/src/main/docker/policy-pdpx.sh
+++ b/packages/policy-xacmlpdp-docker/src/main/docker/policy-pdpx.sh
@@ -1,7 +1,7 @@
#!/usr/bin/env sh
#
# ============LICENSE_START=======================================================
-# Copyright (C) 2019-2021 AT&T Intellectual Property. All rights reserved.
+# Copyright (C) 2019-2022 AT&T Intellectual Property. All rights reserved.
# Modifications Copyright (C) 2019-2022 Nordix Foundation.
# ================================================================================
# Licensed under the Apache License, Version 2.0 (the "License");
@@ -20,6 +20,8 @@
# ============LICENSE_END=========================================================
#
+set -x
+
KEYSTORE="${KEYSTORE:-$POLICY_HOME/etc/ssl/policy-keystore}"
TRUSTSTORE="${TRUSTSTORE:-$POLICY_HOME/etc/ssl/policy-truststore}"
KEYSTORE_PASSWD="${KEYSTORE_PASSWD:-Pol1cy_0nap}"
@@ -55,6 +57,16 @@ if [ -f "${POLICY_HOME}/etc/mounted/logback.xml" ]; then
cp -f "${POLICY_HOME}"/etc/mounted/logback.xml "${POLICY_HOME}"/etc/
fi
+if [ -f "${POLICY_HOME}/etc/mounted/createguardtable.sql" ]; then
+ echo "overriding createguardtable.sql"
+ cp -f "${POLICY_HOME}"/etc/mounted/createguardtable.sql "${POLICY_HOME}"/mysql/sql/
+fi
+
+if [ -f "${POLICY_HOME}/etc/mounted/db.sql" ]; then
+ echo "adding additional db.sql"
+ cp -f "${POLICY_HOME}"/etc/mounted/db.sql "${POLICY_HOME}"/mysql/sql/
+fi
+
# Create operationshistory table
"${POLICY_HOME}"/mysql/bin/create-guard-table.sh