Skip to content

Commit

Permalink
Showing 8 changed files with 134 additions and 71 deletions.
2 changes: 1 addition & 1 deletion Dockerfile
@@ -48,7 +48,7 @@ RUN /opt/container_files/docker-build-bin/containerDockerfileInstall.sh $JAVA_HO
# docker exec -it mygrouper bash

WORKDIR /opt/grouper/grouperWebapp/WEB-INF/
EXPOSE 80 443
EXPOSE 80 443 8080 8443
HEALTHCHECK NONE

ENTRYPOINT ["/usr/local/bin/entrypoint.sh"]
8 changes: 5 additions & 3 deletions Dockerfile3
@@ -1,4 +1,6 @@
FROM i2incommon/grouper:4.3.0
FROM i2incommon/grouper:5.7.0

ENTRYPOINT ["ping"]
CMD ["google.com"]
COPY container_files/usr-local-bin /usr/local/bin
COPY container_files /opt

EXPOSE 8080 8443 8009
4 changes: 2 additions & 2 deletions container_files/tomcat/conf/server.xml.grouper
@@ -169,9 +169,9 @@
<!--
<Valve className="org.apache.catalina.authenticator.SingleSignOn" />
-->
<!--GROUPER_REMOTE_CIDR_VALVE-->
<!--GROUPER_TOMCAT_REMOTE_CIDR_VALVE-->

<!--GROUPER_REMOTE_IP_VALVE-->
<!--GROUPER_TOMCAT_REMOTE_IP_VALVE-->

<!-- Access log processes all example.
Documentation at: /docs/config/valve.html
6 changes: 3 additions & 3 deletions container_files/tomcat/conf/server.xml.grouper.patch
@@ -1,5 +1,5 @@
--- server.xml.original 2023-08-21 10:59:20.000000000 -0400
+++ server.xml.grouper 2023-12-29 16:10:49.000000000 -0500
+++ server.xml.grouper 2023-12-31 16:12:56.000000000 -0500
@@ -66,11 +66,12 @@
APR (HTTP/AJP) Connector: /docs/apr.html
Define a non-SSL/TLS HTTP/1.1 Connector on port 8080
@@ -37,9 +37,9 @@
<!--
<Valve className="org.apache.catalina.authenticator.SingleSignOn" />
-->
+ <!--GROUPER_REMOTE_CIDR_VALVE-->
+ <!--GROUPER_TOMCAT_REMOTE_CIDR_VALVE-->
+
+ <!--GROUPER_REMOTE_IP_VALVE-->
+ <!--GROUPER_TOMCAT_REMOTE_IP_VALVE-->

<!-- Access log processes all example.
Documentation at: /docs/config/valve.html
14 changes: 9 additions & 5 deletions container_files/usr-local-bin/libraryPrep.sh
@@ -287,20 +287,20 @@ prep_finishBegin() {
export GROUPER_CHOWN_DIRS=true
fi
if [ -z "$GROUPER_TOMCAT_HTTP_PORT" ]; then
echo "grouperContainer; INFO: (libraryPrep.sh-prep_finishBegin) export GROUPER_TOMCAT_HTTP_PORT=8080"
export GROUPER_TOMCAT_HTTP_PORT=8080
echo "grouperContainer; INFO: (libraryPrep.sh-prep_finishBegin) export GROUPER_TOMCAT_HTTP_PORT=-1"
export GROUPER_TOMCAT_HTTP_PORT=-1
fi
if [ -z "$GROUPER_TOMCAT_HTTPS_PORT" ]; then
echo "grouperContainer; INFO: (libraryPrep.sh-prep_finishBegin) export GROUPER_TOMCAT_HTTPS_PORT=8443"
export GROUPER_TOMCAT_HTTP_PORT=8443
export GROUPER_TOMCAT_HTTPS_PORT=8443
fi
if [ -z "$GROUPER_TOMCAT_MAX_HEADER_COUNT" ]; then
echo "grouperContainer; INFO: (libraryPrep.sh-prep_finishBegin) export GROUPER_TOMCAT_MAX_HEADER_COUNT=200"
export GROUPER_TOMCAT_MAX_HEADER_COUNT=200
fi
if [ -z "$GROUPER_TOMCAT_AJP_PORT" ]; then
echo "grouperContainer; INFO: (libraryPrep.sh-prep_finishBegin) export GROUPER_TOMCAT_AJP_PORT=8009"
export GROUPER_TOMCAT_AJP_PORT=8009
echo "grouperContainer; INFO: (libraryPrep.sh-prep_finishBegin) export GROUPER_TOMCAT_AJP_PORT=-1"
export GROUPER_TOMCAT_AJP_PORT=-1
fi
if [ -z "$GROUPER_TOMCAT_SHUTDOWN_PORT" ]; then
echo "grouperContainer; INFO: (libraryPrep.sh-prep_finishBegin) export GROUPER_TOMCAT_SHUTDOWN_PORT=8005"
@@ -311,6 +311,10 @@ prep_finishBegin() {
echo "grouperContainer; INFO: (libraryPrep.sh-prep_finishBegin) export GROUPER_TOMCAT_HTTPS_ALIAS=localhost"
export GROUPER_TOMCAT_HTTPS_ALIAS=localhost
fi
if [ -z "$GROUPER_TOMCAT_LOG_ACCESS_DIRECTORY" ]; then
echo "grouperContainer; INFO: (libraryPrep.sh-prep_finishBegin) export GROUPER_TOMCAT_LOG_ACCESS_DIRECTORY=/opt/grouper/logs"
export GROUPER_TOMCAT_LOG_ACCESS_DIRECTORY=/opt/grouper/logs
fi

if [ -z "$GROUPER_GSH_JVMARGS" ] ; then
echo "grouperContainer; INFO: (libraryPrep.sh-prep_finishBegin) export GROUPER_GSH_JVMARGS=\"-Djavax.net.ssl.trustStore=/etc/pki/java/cacerts\""
21 changes: 21 additions & 0 deletions container_files/usr-local-bin/librarySetupFiles.sh
@@ -100,6 +100,27 @@ setupFiles_localLogging() {
echo "grouperContainer; INFO: (librarySetupFiles.sh-setupFiles_localLogging) sed -i \"s|__FILEEND__|-->|g\" /opt/grouper/grouperWebapp/WEB-INF/classes/log4j2.xml, result: $?"
if [ $returnCode != 0 ]; then exit $returnCode; fi
fi
if [ "$GROUPER_LOG_TO_PIPE" = "true" ] && [ "1" = "2" ]; then
sed -i "s|__LOGPIPESTART__||g" /opt/grouper/grouperWebapp/WEB-INF/classes/log4j2.xml
returnCode=$?
echo "grouperContainer; INFO: (librarySetupFiles.sh-setupFiles_localLogging) sed -i \"s|__LOGPIPESTART__||g\" /opt/grouper/grouperWebapp/WEB-INF/classes/log4j2.xml, result: $?"
if [ $returnCode != 0 ]; then exit $returnCode; fi

sed -i "s|__LOGPIPEEND__||g" /opt/grouper/grouperWebapp/WEB-INF/classes/log4j2.xml
returnCode=$?
echo "grouperContainer; INFO: (librarySetupFiles.sh-setupFiles_localLogging) sed -i \"s|__LOGPIPEEND__||g\" /opt/grouper/grouperWebapp/WEB-INF/classes/log4j2.xml, result: $?"
if [ $returnCode != 0 ]; then exit $returnCode; fi
else
sed -i "s|__LOGPIPESTART__|<!--|g" /opt/grouper/grouperWebapp/WEB-INF/classes/log4j2.xml
returnCode=$?
echo "grouperContainer; INFO: (librarySetupFiles.sh-setupFiles_localLogging) sed -i \"s|__LOGPIPESTART__|<!--|g\" /opt/grouper/grouperWebapp/WEB-INF/classes/log4j2.xml, result: $?"
if [ $returnCode != 0 ]; then exit $returnCode; fi

sed -i "s|__LOGPIPEEND__|-->|g" /opt/grouper/grouperWebapp/WEB-INF/classes/log4j2.xml
returnCode=$?
echo "grouperContainer; INFO: (librarySetupFiles.sh-setupFiles_localLogging) sed -i \"s|__LOGPIPEEND__|-->|g\" /opt/grouper/grouperWebapp/WEB-INF/classes/log4j2.xml, result: $?"
if [ $returnCode != 0 ]; then exit $returnCode; fi
fi

# add semicolons
LOCAL_ENV=
129 changes: 73 additions & 56 deletions container_files/usr-local-bin/librarySetupFilesTomcat.sh

Large diffs are not rendered by default.

21 changes: 20 additions & 1 deletion run3.sh 100644 → 100755
@@ -1,4 +1,23 @@
#!/bin/bash

docker run -d --name my-grouper3 my-grouper3:latest
docker rm -f my-grouper3

docker run -d -p 8080:8080 -p 8443:8443 \
-e GROUPER_SELF_SIGNED_CERT=true -e GROUPER_UI_CONFIGURATION_EDITOR_SOURCEIPADDRESSES='0.0.0.0/0' \
-e GROUPER_TOMCAT_HTTP_PORT=8080 -e GROUPER_TOMCAT_AJP_PORT=-1 -e GROUPER_TOMCAT_HTTPS_PORT=-1 \
-e GROUPER_START_DELAY_SECONDS=10 -e GROUPER_UI_GROUPER_AUTH=true \
-e GROUPER_WS_GROUPER_AUTH=true -e GROUPER_SCIM_GROUPER_AUTH=true \
-e GROUPER_QUICKSTART=true -e GROUPER_RUN_TOMCAT=true \
-e GROUPER_UI=true \
-e GROUPER_TOMCAT_REMOTE_IP_VALVE=true \
-e GROUPER_TOMCAT_REMOTE_IP_INTERNAL_PROXIES=abc -e GROUPER_TOMCAT_REMOTE_IP_HEADER=xyz \
-e GROUPER_TOMCAT_REMOTE_IP_PROXIES_HEADER=def -e GROUPER_TOMCAT_REMOTE_IP_TRUSTED_PROXIES=fgh \
-e GROUPER_TOMCAT_REMOTE_IP_PROTOCOL_HEADER=hij -e GROUPER_TOMCAT_REMOTE_IP_PROTOCOL_HEADER_HTTPS_VALUE=jkl \
-e GROUPER_TOMCAT_REMOTE_IP_HTTP_SERVER_PORT=123 -e GROUPER_TOMCAT_REMOTE_IP_HTTPS_SERVER_PORT=234 \
-e GROUPER_LOG_TO_HOST=true -e GROUPER_TOMCAT_LOG_ACCESS=true \
-e GROUPER_DATABASE_PASSWORD=pass -e GROUPER_DATABASE_USERNAME=postgres \
-e GROUPERSYSTEM_QUICKSTART_PASS=pass -e GROUPER_MORPHSTRING_ENCRYPT_KEY=abc123 \
-e GROUPER_DATABASE_URL=jdbc:postgresql://192.168.86.28:5433/postgres -e GROUPER_AUTO_DDL_UPTOVERSION='v5.*.*' \
--name my-grouper3 my-grouper3:latest quickstart

# containerPing

0 comments on commit 30cb91f

Please sign in to comment.