Skip to content

Commit

Permalink
GRP-3722: GROUPER_PUT_JAVA_HOME_IN_BASHRC, GRP-3723: GROUPER_JAVA_HOME
Browse files Browse the repository at this point in the history
  • Loading branch information
mchyzer committed Dec 10, 2021
1 parent 0af1439 commit 6c2c9c6
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 2 deletions.
8 changes: 8 additions & 0 deletions container_files/usr-local-bin/libraryPrep.sh
Original file line number Diff line number Diff line change
Expand Up @@ -474,6 +474,14 @@ prep_finishEnd() {
echo "grouperContainer; INFO: (libraryPrep.sh-prep_finishEnd) export GROUPER_CONTEXT_COOKIES=true"
export GROUPER_CONTEXT_COOKIES=true
fi
if [ -z "$GROUPER_PUT_JAVA_HOME_IN_BASHRC" ]; then
echo "grouperContainer; INFO: (libraryPrep.sh-prep_finishEnd) export GROUPER_PUT_JAVA_HOME_IN_BASHRC=true"
export GROUPER_PUT_JAVA_HOME_IN_BASHRC=true
fi
if [ -z "$GROUPER_JAVA_HOME" ]; then
echo "grouperContainer; INFO: (libraryPrep.sh-prep_finishEnd) export GROUPER_JAVA_HOME=/usr/lib/jvm/java-1.8.0-amazon-corretto"
export GROUPER_JAVA_HOME=/usr/lib/jvm/java-1.8.0-amazon-corretto
fi
if [ -z "$GROUPER_TOMCAT_LOG_ACCESS" ]; then
echo "grouperContainer; INFO: (libraryPrep.sh-prep_finishEnd) export GROUPER_TOMCAT_LOG_ACCESS=false"
export GROUPER_TOMCAT_LOG_ACCESS=false
Expand Down
6 changes: 4 additions & 2 deletions container_files/usr-local-bin/librarySetupFiles.sh
Original file line number Diff line number Diff line change
Expand Up @@ -124,8 +124,10 @@ setupFiles_storeEnvVars() {
echo "" >> /etc/bashrc
echo "export GROUPER_GSH_CHECK_USER=$GROUPER_GSH_CHECK_USER" >> /etc/bashrc
echo "export GROUPER_GSH_USER=$GROUPER_GSH_USER" >> /etc/bashrc
echo "export JAVA_HOME=$JAVA_HOME" >> /etc/bashrc
echo "export PATH=$JAVA_HOME/bin:\$PATH" >> /etc/bashrc
if [ "$GROUPER_PUT_JAVA_HOME_IN_BASHRC" = "true" ]; then
echo "export JAVA_HOME=$GROUPER_JAVA_HOME" >> /etc/bashrc
echo "export PATH=$GROUPER_JAVA_HOME/bin:\$PATH" >> /etc/bashrc
fi
echo "" >> /etc/bashrc
returnCode=$?
echo "grouperContainer; INFO: (librarySetupFiles.sh-setupFiles_storeEnvVars) echo env var script to /etc/bashrc, result: $returnCode"
Expand Down

0 comments on commit 6c2c9c6

Please sign in to comment.