Merge "[COMMON][ES] Simplify cert retrieval script"
[oom.git] / kubernetes / common / cert-wrapper / resources / import-custom-certs.sh
index ec1ce94..6df7505 100755 (executable)
@@ -1,7 +1,7 @@
-#!/bin/bash
+#!/bin/sh
 {{/*
 
-# Copyright © 2020 Bell Canada
+# Copyright © 2020-2021 Bell Canada
 #
 # Licensed under the Apache License, Version 2.0 (the "License");
 # you may not use this file except in compliance with the License.
@@ -58,7 +58,8 @@ done
 # Prepare truststore output file
 if [ "$AAF_ENABLED" = "true" ]
   then
-    mv $WORK_DIR/$ONAP_TRUSTSTORE $WORK_DIR/$TRUSTSTORE_OUTPUT_FILENAME
+    echo "AAF is enabled, use 'AAF' truststore"
+    export TRUSTSTORE_OUTPUT_FILENAME=${ONAP_TRUSTSTORE}
   else
     echo "AAF is disabled, using JRE truststore"
     cp $JRE_TRUSTSTORE $WORK_DIR/$TRUSTSTORE_OUTPUT_FILENAME