Skip to content
Permalink
eee2540265
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Go to file
@mchyzer
Latest commit eee2540 Mar 17, 2025 History
4 contributors

Users who have contributed to this file

@mchyzer @chubing @pcaskey @credman
55 lines (43 sloc) 2.27 KB
FROM --platform=$TARGETPLATFORM rockylinux/rockylinux:9.4
LABEL author="tier-packaging@internet2.edu <tier-packaging@internet2.edu>" \
Vendor="TIER" \
ImageType="Grouper" \
ImageName=$imagename \
ImageOS=centos7
ARG GROUPER_CONTAINER_VERSION
ENV GROUPER_VERSION=5.17.1 \
GROUPER_CONTAINER_VERSION=5.17.1 \
JAVA_HOME=/usr/lib/jvm/java-17-amazon-corretto \
PATH=$PATH:$JAVA_HOME/bin \
GROUPER_HOME=/opt/grouper/grouperWebapp/WEB-INF
# net-tools curl mlocate strace telnet man vim rsyslog cron mod_ssl cronie
RUN dnf update -y \
&& dnf --allowerasing install -y logrotate python3-pip rsync sudo patch wget tar unzip dos2unix file net-tools diffutils curl mlocate logrotate strace telnet man vim rsyslog cronie findutils procps \
&& pip3 install --upgrade setuptools \
&& dnf clean -y all \
&& groupadd -g 994 -r tomcat \
&& useradd -u 996 -r -m -s /sbin/nologin -g tomcat tomcat \
&& mkdir -p /opt/container_files
# Install Corretto Java JDK
#Corretto download page: https://docs.aws.amazon.com/corretto/latest/corretto-8-ug/downloads-list.html
# Install Corretto Java JDK (newer more arch independent way)
RUN rpm --import https://yum.corretto.aws/corretto.key \
&& curl -L -o /etc/yum.repos.d/corretto.repo https://yum.corretto.aws/corretto.repo \
&& dnf --allowerasing install -y java-17-amazon-corretto-devel
# real copy command (if not caching), uncomment this and change comments of COPY above to work on install script
COPY container_files/ /opt/container_files/
RUN chmod +x /opt/container_files/docker-build-bin/*.sh \
&& /opt/container_files/docker-build-bin/containerDockerfileInstallDos2unix.sh /opt/container_files \
&& /opt/container_files/docker-build-bin/containerDockerfileInstallGrouper.sh $JAVA_HOME $GROUPER_VERSION \
&& /opt/container_files/docker-build-bin/containerDockerfileInstall.sh $JAVA_HOME $GROUPER_VERSION
# testing container
# see output with docker build . --tag my:grouper
# DOCKER_BUILDKIT=0 docker build --progress=plain -t mygrouper .
# docker run --detach --name mygrouper mygrouper:latest
# docker exec -it mygrouper bash
WORKDIR /opt/grouper/grouperWebapp/WEB-INF/
EXPOSE 80 443 8080 8443
HEALTHCHECK NONE
ENTRYPOINT ["/usr/local/bin/entrypoint.sh"]
#ENTRYPOINT ["ping"]
#CMD ["google.com"]