From cde7eca94f6eedf0c23635e316f01bb60f5e4a6e Mon Sep 17 00:00:00 2001 From: Ramesh Parthasarathy Date: Tue, 11 Feb 2020 18:39:37 +0000 Subject: Added AAF SSL certs related changes if AAF_SSL_CERTS_ENABLED environment variable is turned on it will try initialize other environment variables related to AAF SSL certs. SO OOM application overrides will be dynamically configured whether or not to use AAF SSL certs. Issue-ID: SO-2451 Signed-off-by: Ramesh Parthasarathy(rp6768) Change-Id: I46eb8fa2f8f790232635a3e1926fd2464c48d173 --- .../main/docker/docker-files/scripts/start-app.sh | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/packages/docker/src/main/docker/docker-files/scripts/start-app.sh b/packages/docker/src/main/docker/docker-files/scripts/start-app.sh index cea680c682..75d64fefa0 100644 --- a/packages/docker/src/main/docker/docker-files/scripts/start-app.sh +++ b/packages/docker/src/main/docker/docker-files/scripts/start-app.sh @@ -83,6 +83,26 @@ fi jvmargs="${JVM_ARGS} -Dspring.profiles.active=${ACTIVE_PROFILE} -Djava.security.egd=file:/dev/./urandom -Dlogs_dir=${LOG_PATH} -Dlogging.config=/app/logback-spring.xml $jksargs -Dspring.config.additional-location=$CONFIG_PATH ${SSL_DEBUG} ${DISABLE_SNI}" + +read_properties(){ + while IFS="=" read -r key value; do + case "${key}" in + '#'*) ;; + *) + eKey=$(echo $key | tr '[:lower:]' '[:upper:]') + export "$eKey"="$value" + esac + done <<-EOF + $1 + EOF +} + + + +if [ -n "${AAF_SSL_CERTS_ENABLED}" ]; then +read_properties "$(head -n 4 /app/certs/.passphrases)" +fi + echo "JVM Arguments: ${jvmargs}" java ${jvmargs} -jar app.jar -- cgit 1.2.3-korg