Use the cert generated by AAF 84/119784/1
authorGuangrongFu <fu.guangrong@zte.com.cn>
Thu, 25 Mar 2021 02:31:40 +0000 (10:31 +0800)
committerGuangrongFu <fu.guangrong@zte.com.cn>
Thu, 25 Mar 2021 02:31:40 +0000 (10:31 +0800)
Change-Id: I99a21dfab3aa47d0a7223ef9369e63bf6aa526ce
Issue-ID: HOLMES-426
Signed-off-by: GuangrongFu <fu.guangrong@zte.com.cn>
rulemgt-standalone/src/main/assembly/bin/run.sh

index 49ffc53..6594eaf 100644 (file)
@@ -81,6 +81,15 @@ echo ENABLE_ENCRYPT=${ENABLE_ENCRYPT}
 
 KEY_PATH="$main_path/conf/holmes.keystore"
 KEY_PASSWORD="holmes"
+
+if [ -f "/opt/app/osaaf/local/org.onap.holmes-rule-mgmt.p12" ]; then
+    KEY_PATH="/opt/app/osaaf/local/org.onap.holmes-rule-mgmt.p12"
+    KEY_PASSWORD=`head -n1 "/opt/app/osaaf/local/mycreds.prop" | cut -d= -f2`
+fi
+
+echo "KEY_PATH=$KEY_PATH"
+echo "KEY_PASS=$KEY_PASSWORD"
+
 #HTTPS Configurations
 sed -i "s|keyStorePath:.*|keyStorePath: $KEY_PATH|" "$main_path/conf/rulemgt.yml"
 sed -i "s|keyStorePassword:.*|keyStorePassword: $KEY_PASSWORD|" "$main_path/conf/rulemgt.yml"