From ce886b394c9d793e83227eb0352901d1ccf64a4e Mon Sep 17 00:00:00 2001 From: mbroz2 Date: Thu, 6 Jul 2023 08:46:58 -0500 Subject: [PATCH 01/19] revert the FROM statement back to ibmjava:8-ubi (#517) --- ga/23.0.0.3/kernel/Dockerfile.ubi.ibmjava8 | 2 +- ga/23.0.0.6/kernel/Dockerfile.ubi.ibmjava8 | 4 ++-- ga/latest/kernel/Dockerfile.ubi.ibmjava8 | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/ga/23.0.0.3/kernel/Dockerfile.ubi.ibmjava8 b/ga/23.0.0.3/kernel/Dockerfile.ubi.ibmjava8 index bb605e028..b7015c750 100644 --- a/ga/23.0.0.3/kernel/Dockerfile.ubi.ibmjava8 +++ b/ga/23.0.0.3/kernel/Dockerfile.ubi.ibmjava8 @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM icr.io/appcafe/ibmjava:8-sdk-ubi8 +FROM ibmjava:8-ubi USER root diff --git a/ga/23.0.0.6/kernel/Dockerfile.ubi.ibmjava8 b/ga/23.0.0.6/kernel/Dockerfile.ubi.ibmjava8 index b5830d066..74d122601 100644 --- a/ga/23.0.0.6/kernel/Dockerfile.ubi.ibmjava8 +++ b/ga/23.0.0.6/kernel/Dockerfile.ubi.ibmjava8 @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM icr.io/appcafe/ibmjava:8-sdk-ubi8 AS getRuntime +FROM ibmjava:8-ubi AS getRuntime USER root @@ -38,7 +38,7 @@ RUN yum -y install unzip wget openssl \ && chmod -R g+rw /opt/ibm/wlp \ && cp -a /opt/ibm/wlp/lafiles/. /licenses/ -FROM icr.io/appcafe/ibmjava:8-sdk-ubi8 +FROM ibmjava:8-ubi USER root diff --git a/ga/latest/kernel/Dockerfile.ubi.ibmjava8 b/ga/latest/kernel/Dockerfile.ubi.ibmjava8 index b5830d066..74d122601 100644 --- a/ga/latest/kernel/Dockerfile.ubi.ibmjava8 +++ b/ga/latest/kernel/Dockerfile.ubi.ibmjava8 @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM icr.io/appcafe/ibmjava:8-sdk-ubi8 AS getRuntime +FROM ibmjava:8-ubi AS getRuntime USER root @@ -38,7 +38,7 @@ RUN yum -y install unzip wget openssl \ && chmod -R g+rw /opt/ibm/wlp \ && cp -a /opt/ibm/wlp/lafiles/. /licenses/ -FROM icr.io/appcafe/ibmjava:8-sdk-ubi8 +FROM ibmjava:8-ubi USER root From 91608e6092f8ebda9eeb748a446a602ca7bf99b2 Mon Sep 17 00:00:00 2001 From: Michal Broz Date: Thu, 20 Jul 2023 23:13:24 -0500 Subject: [PATCH 02/19] revert ubuntu based images back to single stage --- ga/23.0.0.6/full/Dockerfile.ubuntu.ibmjava8 | 34 ++++-------- ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk11 | 30 +++------- ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk17 | 30 +++------- ga/23.0.0.6/kernel/Dockerfile.ubuntu.ibmjava8 | 55 ++++++------------- .../kernel/Dockerfile.ubuntu.openjdk11 | 52 ++++++------------ .../kernel/Dockerfile.ubuntu.openjdk17 | 52 ++++++------------ ga/latest/full/Dockerfile.ubuntu.ibmjava8 | 34 ++++-------- ga/latest/full/Dockerfile.ubuntu.openjdk11 | 30 +++------- ga/latest/full/Dockerfile.ubuntu.openjdk17 | 30 +++------- ga/latest/kernel/Dockerfile.ubuntu.ibmjava8 | 55 ++++++------------- ga/latest/kernel/Dockerfile.ubuntu.openjdk11 | 52 ++++++------------ ga/latest/kernel/Dockerfile.ubuntu.openjdk17 | 52 ++++++------------ 12 files changed, 148 insertions(+), 358 deletions(-) diff --git a/ga/23.0.0.6/full/Dockerfile.ubuntu.ibmjava8 b/ga/23.0.0.6/full/Dockerfile.ubuntu.ibmjava8 index b5583be27..a437bca4c 100644 --- a/ga/23.0.0.6/full/Dockerfile.ubuntu.ibmjava8 +++ b/ga/23.0.0.6/full/Dockerfile.ubuntu.ibmjava8 @@ -12,33 +12,20 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM websphere-liberty:23.0.0.6-kernel-java8-ibmjava AS installBundle -ARG VERBOSE=false -ARG REPOSITORIES_PROPERTIES="" +FROM websphere-liberty:kernel-java8-ibmjava -# If there is a local copy of the repository use that instead -COPY resources/ /tmp/ - -# Install the base bundle -RUN set -eux; \ - if [ ! -z "$REPOSITORIES_PROPERTIES" ]; then \ - mkdir /opt/ibm/wlp/etc/; \ - echo "$REPOSITORIES_PROPERTIES" > /opt/ibm/wlp/etc/repositories.properties; \ - installUtility install --acceptLicense baseBundle; \ - rm /opt/ibm/wlp/etc/repositories.properties; \ - elif [ -f /tmp/wlpRepo.zip ]; then \ - installUtility install --acceptLicense baseBundle --from=/tmp/wlpRepo.zip; \ - else \ - installUtility install --acceptLicense baseBundle; \ - fi; \ - rm -rf /output/workarea /output/logs; \ - find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw; +USER root -FROM websphere-liberty:23.0.0.6-kernel-java8-ibmjava ARG VERBOSE=false +ARG REPOSITORIES_PROPERTIES="" -# Copy the runtime -COPY --from=installBundle /opt/ibm/wlp /opt/ibm/wlp +# Install the base bundle +RUN if [ ! -z $REPOSITORIES_PROPERTIES ]; then mkdir /opt/ibm/wlp/etc/ \ + && echo $REPOSITORIES_PROPERTIES > /opt/ibm/wlp/etc/repositories.properties; fi \ + && installUtility install --acceptLicense baseBundle \ + && if [ ! -z $REPOSITORIES_PROPERTIES ]; then rm /opt/ibm/wlp/etc/repositories.properties; fi \ + && rm -rf /output/workarea /output/logs \ + && find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw COPY --chown=1001:0 server.xml /config/ @@ -46,4 +33,3 @@ COPY --chown=1001:0 server.xml /config/ RUN if [ "$OPENJ9_SCC" = "true" ]; then populate_scc.sh; fi \ && rm -rf /output/messaging /output/resources/security /logs/* $WLP_OUTPUT_DIR/.classCache \ && find /opt/ibm/wlp/output ! -path "*.classCache*" ! -perm -g=rwx -print0 | xargs -0 -r chmod g+rwx - diff --git a/ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk11 b/ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk11 index d983f604e..a28e2d432 100644 --- a/ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk11 +++ b/ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk11 @@ -12,36 +12,20 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM websphere-liberty:23.0.0.6-kernel-java11-openj9 AS installBundle +FROM websphere-liberty:kernel-java11-openj9 USER root ARG VERBOSE=false ARG REPOSITORIES_PROPERTIES="" -# If there is a local copy of the repository use that instead -COPY resources/ /tmp/ - # Install the base bundle -RUN set -eux; \ - if [ ! -z "$REPOSITORIES_PROPERTIES" ]; then \ - mkdir /opt/ibm/wlp/etc/; \ - echo "$REPOSITORIES_PROPERTIES" > /opt/ibm/wlp/etc/repositories.properties; \ - installUtility install --acceptLicense baseBundle; \ - rm /opt/ibm/wlp/etc/repositories.properties; \ - elif [ -f /tmp/wlpRepo.zip ]; then \ - installUtility install --acceptLicense baseBundle --from=/tmp/wlpRepo.zip; \ - else \ - installUtility install --acceptLicense baseBundle; \ - fi; \ - rm -rf /output/workarea /output/logs; \ - find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw; - -FROM websphere-liberty:23.0.0.6-kernel-java11-openj9 -ARG VERBOSE=false - -# Copy the runtime -COPY --from=installBundle /opt/ibm/wlp /opt/ibm/wlp +RUN if [ ! -z $REPOSITORIES_PROPERTIES ]; then mkdir /opt/ibm/wlp/etc/ \ + && echo $REPOSITORIES_PROPERTIES > /opt/ibm/wlp/etc/repositories.properties; fi \ + && installUtility install --acceptLicense baseBundle \ + && if [ ! -z $REPOSITORIES_PROPERTIES ]; then rm /opt/ibm/wlp/etc/repositories.properties; fi \ + && rm -rf /output/workarea /output/logs \ + && find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw COPY --chown=1001:0 server.xml /config/ diff --git a/ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk17 b/ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk17 index 28fb016dd..d3a5494eb 100644 --- a/ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk17 +++ b/ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk17 @@ -12,36 +12,20 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM websphere-liberty:23.0.0.6-kernel-java17-openj9 AS installBundle +FROM websphere-liberty:kernel-java17-openj9 USER root ARG VERBOSE=false ARG REPOSITORIES_PROPERTIES="" -# If there is a local copy of the repository use that instead -COPY resources/ /tmp/ - # Install the base bundle -RUN set -eux; \ - if [ ! -z "$REPOSITORIES_PROPERTIES" ]; then \ - mkdir /opt/ibm/wlp/etc/; \ - echo "$REPOSITORIES_PROPERTIES" > /opt/ibm/wlp/etc/repositories.properties; \ - installUtility install --acceptLicense baseBundle; \ - rm /opt/ibm/wlp/etc/repositories.properties; \ - elif [ -f /tmp/wlpRepo.zip ]; then \ - installUtility install --acceptLicense baseBundle --from=/tmp/wlpRepo.zip; \ - else \ - installUtility install --acceptLicense baseBundle; \ - fi; \ - rm -rf /output/workarea /output/logs; \ - find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw; - -FROM websphere-liberty:23.0.0.6-kernel-java17-openj9 -ARG VERBOSE=false - -# Copy the runtime -COPY --from=installBundle /opt/ibm/wlp /opt/ibm/wlp +RUN if [ ! -z $REPOSITORIES_PROPERTIES ]; then mkdir /opt/ibm/wlp/etc/ \ + && echo $REPOSITORIES_PROPERTIES > /opt/ibm/wlp/etc/repositories.properties; fi \ + && installUtility install --acceptLicense baseBundle \ + && if [ ! -z $REPOSITORIES_PROPERTIES ]; then rm /opt/ibm/wlp/etc/repositories.properties; fi \ + && rm -rf /output/workarea /output/logs \ + && find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw COPY --chown=1001:0 server.xml /config/ diff --git a/ga/23.0.0.6/kernel/Dockerfile.ubuntu.ibmjava8 b/ga/23.0.0.6/kernel/Dockerfile.ubuntu.ibmjava8 index 0b58a7f43..1b3b88a7e 100644 --- a/ga/23.0.0.6/kernel/Dockerfile.ubuntu.ibmjava8 +++ b/ga/23.0.0.6/kernel/Dockerfile.ubuntu.ibmjava8 @@ -12,32 +12,6 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM ibmjava:8-jre AS getRuntime - -USER root - -ARG VERBOSE=false - -# Install WebSphere Liberty -ARG LIBERTY_VERSION=23.0.0.6 -ARG LIBERTY_URL -ARG DOWNLOAD_OPTIONS="" - -# If there is a local copy of the image use that instead -COPY resources/ /tmp/ - -RUN apt-get update \ - && apt-get install -y --no-install-recommends unzip wget openssl \ - && rm -rf /var/lib/apt/lists/* \ - && mkdir -p /licenses/ \ - && useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ - && LIBERTY_URL=${LIBERTY_URL:-$(wget -q -O - https://public.dhe.ibm.com/ibmdl/export/pub/software/websphere/wasdev/downloads/wlp/index.yml | grep -E "^\s*kernel:.*${LIBERTY_VERSION}\.zip" | sed -n 's/\s*kernel:\s//p' | tr -d '\r' )} \ - && if [ ! -f /tmp/wlp.zip ]; then wget $DOWNLOAD_OPTIONS $LIBERTY_URL -U UA-IBM-WebSphere-Liberty-Docker -O /tmp/wlp.zip; fi \ - && unzip -q /tmp/wlp.zip -d /opt/ibm \ - && chown -R 1001:0 /opt/ibm/wlp \ - && chmod -R g+rw /opt/ibm/wlp \ - && cp -a /opt/ibm/wlp/lafiles/. /licenses/ - FROM ibmjava:8-jre USER root @@ -95,20 +69,27 @@ RUN set -eux; \ curl -LfsSo /usr/bin/dumb-init ${DUMB_INIT_URL}; \ echo "${DUMB_INIT_SHA256} */usr/bin/dumb-init" | sha256sum -c -; \ chmod +x /usr/bin/dumb-init; \ - apt-get purge --auto-remove -y wget; \ + apt-get purge --auto-remove -y curl; \ rm -rf /var/lib/apt/lists/*; -# Add default user 1001 and create wlp with right user/permissions before copying -RUN useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ - && mkdir -p /opt/ibm/wlp \ - && chown -R 1001:0 /opt/ibm/wlp \ - && chmod -R g+rw /opt/ibm/wlp - -# Copy the runtime and licenses -COPY --from=getRuntime --chown=1001:0 /opt/ibm/wlp /opt/ibm/wlp -COPY --from=getRuntime /licenses /licenses +# Install WebSphere Liberty +ARG LIBERTY_URL +ARG DOWNLOAD_OPTIONS="" -RUN apt-get install -y --no-install-recommends openssl \ +RUN apt-get update \ + && apt-get install -y --no-install-recommends unzip wget openssl \ + && rm -rf /var/lib/apt/lists/* \ + && mkdir -p /licenses/ \ + && useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ + && LIBERTY_URL=${LIBERTY_URL:-$(wget -q -O - https://public.dhe.ibm.com/ibmdl/export/pub/software/websphere/wasdev/downloads/wlp/index.yml | grep -E "^\s*kernel:.*${LIBERTY_VERSION}\.zip" | sed -n 's/\s*kernel:\s//p' | tr -d '\r' )} \ + && wget $DOWNLOAD_OPTIONS $LIBERTY_URL -U UA-IBM-WebSphere-Liberty-Docker -O /tmp/wlp.zip \ + && unzip -q /tmp/wlp.zip -d /opt/ibm \ + && rm /tmp/wlp.zip \ + && chown -R 1001:0 /opt/ibm/wlp \ + && chmod -R g+rw /opt/ibm/wlp \ + && cp -a /opt/ibm/wlp/lafiles/. /licenses/ \ + && apt-get purge --auto-remove -y unzip \ + && apt-get purge --auto-remove -y wget \ && rm -rf /var/lib/apt/lists/* # Set Path Shortcuts diff --git a/ga/23.0.0.6/kernel/Dockerfile.ubuntu.openjdk11 b/ga/23.0.0.6/kernel/Dockerfile.ubuntu.openjdk11 index 4978eb1fa..27546784c 100644 --- a/ga/23.0.0.6/kernel/Dockerfile.ubuntu.openjdk11 +++ b/ga/23.0.0.6/kernel/Dockerfile.ubuntu.openjdk11 @@ -12,32 +12,6 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM ibm-semeru-runtimes:open-11-jre-focal AS getRuntime - -USER root - -ARG VERBOSE=false - -# Install WebSphere Liberty -ARG LIBERTY_VERSION=23.0.0.6 -ARG LIBERTY_URL -ARG DOWNLOAD_OPTIONS="" - -# If there is a local copy of the image use that instead -COPY resources/ /tmp/ - -RUN apt-get update \ - && apt-get install -y --no-install-recommends unzip wget openssl \ - && rm -rf /var/lib/apt/lists/* \ - && mkdir -p /licenses/ \ - && useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ - && LIBERTY_URL=${LIBERTY_URL:-$(wget -q -O - https://public.dhe.ibm.com/ibmdl/export/pub/software/websphere/wasdev/downloads/wlp/index.yml | grep -E "^\s*kernel:.*${LIBERTY_VERSION}\.zip" | sed -n 's/\s*kernel:\s//p' | tr -d '\r' )} \ - && if [ ! -f /tmp/wlp.zip ]; then wget $DOWNLOAD_OPTIONS $LIBERTY_URL -U UA-IBM-WebSphere-Liberty-Docker -O /tmp/wlp.zip; fi \ - && unzip -q /tmp/wlp.zip -d /opt/ibm \ - && chown -R 1001:0 /opt/ibm/wlp \ - && chmod -R g+rw /opt/ibm/wlp \ - && cp -a /opt/ibm/wlp/lafiles/. /licenses/ - FROM ibm-semeru-runtimes:open-11-jre-focal USER root @@ -94,17 +68,23 @@ RUN set -eux; \ echo "${DUMB_INIT_SHA256} */usr/bin/dumb-init" | sha256sum -c -; \ chmod +x /usr/bin/dumb-init; -# Add default user 1001 and create wlp with right user/permissions before copying -RUN useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ - && mkdir -p /opt/ibm/wlp \ +# Install WebSphere Liberty +ARG LIBERTY_URL +ARG DOWNLOAD_OPTIONS="" +RUN apt-get update \ + && apt-get install -y --no-install-recommends unzip wget \ + && rm -rf /var/lib/apt/lists/* \ + && mkdir -p /licenses/ \ + && useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ + && LIBERTY_URL=${LIBERTY_URL:-$(wget -q -O - https://public.dhe.ibm.com/ibmdl/export/pub/software/websphere/wasdev/downloads/wlp/index.yml | grep -E "^\s*kernel:.*${LIBERTY_VERSION}\.zip" | sed -n 's/\s*kernel:\s//p' | tr -d '\r' )} \ + && wget $DOWNLOAD_OPTIONS $LIBERTY_URL -U UA-IBM-WebSphere-Liberty-Docker -O /tmp/wlp.zip \ + && unzip -q /tmp/wlp.zip -d /opt/ibm \ + && rm /tmp/wlp.zip \ && chown -R 1001:0 /opt/ibm/wlp \ - && chmod -R g+rw /opt/ibm/wlp - -# Copy the runtime and licenses -COPY --from=getRuntime --chown=1001:0 /opt/ibm/wlp /opt/ibm/wlp -COPY --from=getRuntime /licenses /licenses - -RUN apt-get install -y --no-install-recommends openssl \ + && chmod -R g+rw /opt/ibm/wlp \ + && cp -a /opt/ibm/wlp/lafiles/. /licenses/ \ + && apt-get purge --auto-remove -y unzip \ + && apt-get purge --auto-remove -y wget \ && rm -rf /var/lib/apt/lists/* # Set Path Shortcuts diff --git a/ga/23.0.0.6/kernel/Dockerfile.ubuntu.openjdk17 b/ga/23.0.0.6/kernel/Dockerfile.ubuntu.openjdk17 index 7fe7d2e8c..96137b5eb 100644 --- a/ga/23.0.0.6/kernel/Dockerfile.ubuntu.openjdk17 +++ b/ga/23.0.0.6/kernel/Dockerfile.ubuntu.openjdk17 @@ -12,32 +12,6 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM ibm-semeru-runtimes:open-17-jre-focal AS getRuntime - -USER root - -ARG VERBOSE=false - -# Install WebSphere Liberty -ARG LIBERTY_VERSION=23.0.0.6 -ARG LIBERTY_URL -ARG DOWNLOAD_OPTIONS="" - -# If there is a local copy of the image use that instead -COPY resources/ /tmp/ - -RUN apt-get update \ - && apt-get install -y --no-install-recommends unzip wget openssl \ - && rm -rf /var/lib/apt/lists/* \ - && mkdir -p /licenses/ \ - && useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ - && LIBERTY_URL=${LIBERTY_URL:-$(wget -q -O - https://public.dhe.ibm.com/ibmdl/export/pub/software/websphere/wasdev/downloads/wlp/index.yml | grep -E "^\s*kernel:.*${LIBERTY_VERSION}\.zip" | sed -n 's/\s*kernel:\s//p' | tr -d '\r' )} \ - && if [ ! -f /tmp/wlp.zip ]; then wget $DOWNLOAD_OPTIONS $LIBERTY_URL -U UA-IBM-WebSphere-Liberty-Docker -O /tmp/wlp.zip; fi \ - && unzip -q /tmp/wlp.zip -d /opt/ibm \ - && chown -R 1001:0 /opt/ibm/wlp \ - && chmod -R g+rw /opt/ibm/wlp \ - && cp -a /opt/ibm/wlp/lafiles/. /licenses/ - FROM ibm-semeru-runtimes:open-17-jre-focal USER root @@ -94,17 +68,23 @@ RUN set -eux; \ echo "${DUMB_INIT_SHA256} */usr/bin/dumb-init" | sha256sum -c -; \ chmod +x /usr/bin/dumb-init; -# Add default user 1001 and create wlp with right user/permissions before copying -RUN useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ - && mkdir -p /opt/ibm/wlp \ +# Install WebSphere Liberty +ARG LIBERTY_URL +ARG DOWNLOAD_OPTIONS="" +RUN apt-get update \ + && apt-get install -y --no-install-recommends unzip wget \ + && rm -rf /var/lib/apt/lists/* \ + && mkdir -p /licenses/ \ + && useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ + && LIBERTY_URL=${LIBERTY_URL:-$(wget -q -O - https://public.dhe.ibm.com/ibmdl/export/pub/software/websphere/wasdev/downloads/wlp/index.yml | grep -E "^\s*kernel:.*${LIBERTY_VERSION}\.zip" | sed -n 's/\s*kernel:\s//p' | tr -d '\r' )} \ + && wget $DOWNLOAD_OPTIONS $LIBERTY_URL -U UA-IBM-WebSphere-Liberty-Docker -O /tmp/wlp.zip \ + && unzip -q /tmp/wlp.zip -d /opt/ibm \ + && rm /tmp/wlp.zip \ && chown -R 1001:0 /opt/ibm/wlp \ - && chmod -R g+rw /opt/ibm/wlp - -# Copy the runtime and licenses -COPY --from=getRuntime --chown=1001:0 /opt/ibm/wlp /opt/ibm/wlp -COPY --from=getRuntime /licenses /licenses - -RUN apt-get install -y --no-install-recommends openssl \ + && chmod -R g+rw /opt/ibm/wlp \ + && cp -a /opt/ibm/wlp/lafiles/. /licenses/ \ + && apt-get purge --auto-remove -y unzip \ + && apt-get purge --auto-remove -y wget \ && rm -rf /var/lib/apt/lists/* # Set Path Shortcuts diff --git a/ga/latest/full/Dockerfile.ubuntu.ibmjava8 b/ga/latest/full/Dockerfile.ubuntu.ibmjava8 index 395a6922a..a437bca4c 100644 --- a/ga/latest/full/Dockerfile.ubuntu.ibmjava8 +++ b/ga/latest/full/Dockerfile.ubuntu.ibmjava8 @@ -12,33 +12,20 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM websphere-liberty:kernel AS installBundle -ARG VERBOSE=false -ARG REPOSITORIES_PROPERTIES="" +FROM websphere-liberty:kernel-java8-ibmjava -# If there is a local copy of the repository use that instead -COPY resources/ /tmp/ - -# Install the base bundle -RUN set -eux; \ - if [ ! -z "$REPOSITORIES_PROPERTIES" ]; then \ - mkdir /opt/ibm/wlp/etc/; \ - echo "$REPOSITORIES_PROPERTIES" > /opt/ibm/wlp/etc/repositories.properties; \ - installUtility install --acceptLicense baseBundle; \ - rm /opt/ibm/wlp/etc/repositories.properties; \ - elif [ -f /tmp/wlpRepo.zip ]; then \ - installUtility install --acceptLicense baseBundle --from=/tmp/wlpRepo.zip; \ - else \ - installUtility install --acceptLicense baseBundle; \ - fi; \ - rm -rf /output/workarea /output/logs; \ - find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw; +USER root -FROM websphere-liberty:kernel ARG VERBOSE=false +ARG REPOSITORIES_PROPERTIES="" -# Copy the runtime -COPY --from=installBundle /opt/ibm/wlp /opt/ibm/wlp +# Install the base bundle +RUN if [ ! -z $REPOSITORIES_PROPERTIES ]; then mkdir /opt/ibm/wlp/etc/ \ + && echo $REPOSITORIES_PROPERTIES > /opt/ibm/wlp/etc/repositories.properties; fi \ + && installUtility install --acceptLicense baseBundle \ + && if [ ! -z $REPOSITORIES_PROPERTIES ]; then rm /opt/ibm/wlp/etc/repositories.properties; fi \ + && rm -rf /output/workarea /output/logs \ + && find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw COPY --chown=1001:0 server.xml /config/ @@ -46,4 +33,3 @@ COPY --chown=1001:0 server.xml /config/ RUN if [ "$OPENJ9_SCC" = "true" ]; then populate_scc.sh; fi \ && rm -rf /output/messaging /output/resources/security /logs/* $WLP_OUTPUT_DIR/.classCache \ && find /opt/ibm/wlp/output ! -path "*.classCache*" ! -perm -g=rwx -print0 | xargs -0 -r chmod g+rwx - diff --git a/ga/latest/full/Dockerfile.ubuntu.openjdk11 b/ga/latest/full/Dockerfile.ubuntu.openjdk11 index 02fd841cd..a28e2d432 100644 --- a/ga/latest/full/Dockerfile.ubuntu.openjdk11 +++ b/ga/latest/full/Dockerfile.ubuntu.openjdk11 @@ -12,36 +12,20 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM websphere-liberty:kernel-java11-openj9 AS installBundle +FROM websphere-liberty:kernel-java11-openj9 USER root ARG VERBOSE=false ARG REPOSITORIES_PROPERTIES="" -# If there is a local copy of the repository use that instead -COPY resources/ /tmp/ - # Install the base bundle -RUN set -eux; \ - if [ ! -z "$REPOSITORIES_PROPERTIES" ]; then \ - mkdir /opt/ibm/wlp/etc/; \ - echo "$REPOSITORIES_PROPERTIES" > /opt/ibm/wlp/etc/repositories.properties; \ - installUtility install --acceptLicense baseBundle; \ - rm /opt/ibm/wlp/etc/repositories.properties; \ - elif [ -f /tmp/wlpRepo.zip ]; then \ - installUtility install --acceptLicense baseBundle --from=/tmp/wlpRepo.zip; \ - else \ - installUtility install --acceptLicense baseBundle; \ - fi; \ - rm -rf /output/workarea /output/logs; \ - find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw; - -FROM websphere-liberty:kernel-java11-openj9 -ARG VERBOSE=false - -# Copy the runtime -COPY --from=installBundle /opt/ibm/wlp /opt/ibm/wlp +RUN if [ ! -z $REPOSITORIES_PROPERTIES ]; then mkdir /opt/ibm/wlp/etc/ \ + && echo $REPOSITORIES_PROPERTIES > /opt/ibm/wlp/etc/repositories.properties; fi \ + && installUtility install --acceptLicense baseBundle \ + && if [ ! -z $REPOSITORIES_PROPERTIES ]; then rm /opt/ibm/wlp/etc/repositories.properties; fi \ + && rm -rf /output/workarea /output/logs \ + && find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw COPY --chown=1001:0 server.xml /config/ diff --git a/ga/latest/full/Dockerfile.ubuntu.openjdk17 b/ga/latest/full/Dockerfile.ubuntu.openjdk17 index 1241066c1..d3a5494eb 100644 --- a/ga/latest/full/Dockerfile.ubuntu.openjdk17 +++ b/ga/latest/full/Dockerfile.ubuntu.openjdk17 @@ -12,36 +12,20 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM websphere-liberty:kernel-java17-openj9 AS installBundle +FROM websphere-liberty:kernel-java17-openj9 USER root ARG VERBOSE=false ARG REPOSITORIES_PROPERTIES="" -# If there is a local copy of the repository use that instead -COPY resources/ /tmp/ - # Install the base bundle -RUN set -eux; \ - if [ ! -z "$REPOSITORIES_PROPERTIES" ]; then \ - mkdir /opt/ibm/wlp/etc/; \ - echo "$REPOSITORIES_PROPERTIES" > /opt/ibm/wlp/etc/repositories.properties; \ - installUtility install --acceptLicense baseBundle; \ - rm /opt/ibm/wlp/etc/repositories.properties; \ - elif [ -f /tmp/wlpRepo.zip ]; then \ - installUtility install --acceptLicense baseBundle --from=/tmp/wlpRepo.zip; \ - else \ - installUtility install --acceptLicense baseBundle; \ - fi; \ - rm -rf /output/workarea /output/logs; \ - find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw; - -FROM websphere-liberty:kernel-java17-openj9 -ARG VERBOSE=false - -# Copy the runtime -COPY --from=installBundle /opt/ibm/wlp /opt/ibm/wlp +RUN if [ ! -z $REPOSITORIES_PROPERTIES ]; then mkdir /opt/ibm/wlp/etc/ \ + && echo $REPOSITORIES_PROPERTIES > /opt/ibm/wlp/etc/repositories.properties; fi \ + && installUtility install --acceptLicense baseBundle \ + && if [ ! -z $REPOSITORIES_PROPERTIES ]; then rm /opt/ibm/wlp/etc/repositories.properties; fi \ + && rm -rf /output/workarea /output/logs \ + && find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw COPY --chown=1001:0 server.xml /config/ diff --git a/ga/latest/kernel/Dockerfile.ubuntu.ibmjava8 b/ga/latest/kernel/Dockerfile.ubuntu.ibmjava8 index 0b58a7f43..1b3b88a7e 100644 --- a/ga/latest/kernel/Dockerfile.ubuntu.ibmjava8 +++ b/ga/latest/kernel/Dockerfile.ubuntu.ibmjava8 @@ -12,32 +12,6 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM ibmjava:8-jre AS getRuntime - -USER root - -ARG VERBOSE=false - -# Install WebSphere Liberty -ARG LIBERTY_VERSION=23.0.0.6 -ARG LIBERTY_URL -ARG DOWNLOAD_OPTIONS="" - -# If there is a local copy of the image use that instead -COPY resources/ /tmp/ - -RUN apt-get update \ - && apt-get install -y --no-install-recommends unzip wget openssl \ - && rm -rf /var/lib/apt/lists/* \ - && mkdir -p /licenses/ \ - && useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ - && LIBERTY_URL=${LIBERTY_URL:-$(wget -q -O - https://public.dhe.ibm.com/ibmdl/export/pub/software/websphere/wasdev/downloads/wlp/index.yml | grep -E "^\s*kernel:.*${LIBERTY_VERSION}\.zip" | sed -n 's/\s*kernel:\s//p' | tr -d '\r' )} \ - && if [ ! -f /tmp/wlp.zip ]; then wget $DOWNLOAD_OPTIONS $LIBERTY_URL -U UA-IBM-WebSphere-Liberty-Docker -O /tmp/wlp.zip; fi \ - && unzip -q /tmp/wlp.zip -d /opt/ibm \ - && chown -R 1001:0 /opt/ibm/wlp \ - && chmod -R g+rw /opt/ibm/wlp \ - && cp -a /opt/ibm/wlp/lafiles/. /licenses/ - FROM ibmjava:8-jre USER root @@ -95,20 +69,27 @@ RUN set -eux; \ curl -LfsSo /usr/bin/dumb-init ${DUMB_INIT_URL}; \ echo "${DUMB_INIT_SHA256} */usr/bin/dumb-init" | sha256sum -c -; \ chmod +x /usr/bin/dumb-init; \ - apt-get purge --auto-remove -y wget; \ + apt-get purge --auto-remove -y curl; \ rm -rf /var/lib/apt/lists/*; -# Add default user 1001 and create wlp with right user/permissions before copying -RUN useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ - && mkdir -p /opt/ibm/wlp \ - && chown -R 1001:0 /opt/ibm/wlp \ - && chmod -R g+rw /opt/ibm/wlp - -# Copy the runtime and licenses -COPY --from=getRuntime --chown=1001:0 /opt/ibm/wlp /opt/ibm/wlp -COPY --from=getRuntime /licenses /licenses +# Install WebSphere Liberty +ARG LIBERTY_URL +ARG DOWNLOAD_OPTIONS="" -RUN apt-get install -y --no-install-recommends openssl \ +RUN apt-get update \ + && apt-get install -y --no-install-recommends unzip wget openssl \ + && rm -rf /var/lib/apt/lists/* \ + && mkdir -p /licenses/ \ + && useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ + && LIBERTY_URL=${LIBERTY_URL:-$(wget -q -O - https://public.dhe.ibm.com/ibmdl/export/pub/software/websphere/wasdev/downloads/wlp/index.yml | grep -E "^\s*kernel:.*${LIBERTY_VERSION}\.zip" | sed -n 's/\s*kernel:\s//p' | tr -d '\r' )} \ + && wget $DOWNLOAD_OPTIONS $LIBERTY_URL -U UA-IBM-WebSphere-Liberty-Docker -O /tmp/wlp.zip \ + && unzip -q /tmp/wlp.zip -d /opt/ibm \ + && rm /tmp/wlp.zip \ + && chown -R 1001:0 /opt/ibm/wlp \ + && chmod -R g+rw /opt/ibm/wlp \ + && cp -a /opt/ibm/wlp/lafiles/. /licenses/ \ + && apt-get purge --auto-remove -y unzip \ + && apt-get purge --auto-remove -y wget \ && rm -rf /var/lib/apt/lists/* # Set Path Shortcuts diff --git a/ga/latest/kernel/Dockerfile.ubuntu.openjdk11 b/ga/latest/kernel/Dockerfile.ubuntu.openjdk11 index 4978eb1fa..27546784c 100644 --- a/ga/latest/kernel/Dockerfile.ubuntu.openjdk11 +++ b/ga/latest/kernel/Dockerfile.ubuntu.openjdk11 @@ -12,32 +12,6 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM ibm-semeru-runtimes:open-11-jre-focal AS getRuntime - -USER root - -ARG VERBOSE=false - -# Install WebSphere Liberty -ARG LIBERTY_VERSION=23.0.0.6 -ARG LIBERTY_URL -ARG DOWNLOAD_OPTIONS="" - -# If there is a local copy of the image use that instead -COPY resources/ /tmp/ - -RUN apt-get update \ - && apt-get install -y --no-install-recommends unzip wget openssl \ - && rm -rf /var/lib/apt/lists/* \ - && mkdir -p /licenses/ \ - && useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ - && LIBERTY_URL=${LIBERTY_URL:-$(wget -q -O - https://public.dhe.ibm.com/ibmdl/export/pub/software/websphere/wasdev/downloads/wlp/index.yml | grep -E "^\s*kernel:.*${LIBERTY_VERSION}\.zip" | sed -n 's/\s*kernel:\s//p' | tr -d '\r' )} \ - && if [ ! -f /tmp/wlp.zip ]; then wget $DOWNLOAD_OPTIONS $LIBERTY_URL -U UA-IBM-WebSphere-Liberty-Docker -O /tmp/wlp.zip; fi \ - && unzip -q /tmp/wlp.zip -d /opt/ibm \ - && chown -R 1001:0 /opt/ibm/wlp \ - && chmod -R g+rw /opt/ibm/wlp \ - && cp -a /opt/ibm/wlp/lafiles/. /licenses/ - FROM ibm-semeru-runtimes:open-11-jre-focal USER root @@ -94,17 +68,23 @@ RUN set -eux; \ echo "${DUMB_INIT_SHA256} */usr/bin/dumb-init" | sha256sum -c -; \ chmod +x /usr/bin/dumb-init; -# Add default user 1001 and create wlp with right user/permissions before copying -RUN useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ - && mkdir -p /opt/ibm/wlp \ +# Install WebSphere Liberty +ARG LIBERTY_URL +ARG DOWNLOAD_OPTIONS="" +RUN apt-get update \ + && apt-get install -y --no-install-recommends unzip wget \ + && rm -rf /var/lib/apt/lists/* \ + && mkdir -p /licenses/ \ + && useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ + && LIBERTY_URL=${LIBERTY_URL:-$(wget -q -O - https://public.dhe.ibm.com/ibmdl/export/pub/software/websphere/wasdev/downloads/wlp/index.yml | grep -E "^\s*kernel:.*${LIBERTY_VERSION}\.zip" | sed -n 's/\s*kernel:\s//p' | tr -d '\r' )} \ + && wget $DOWNLOAD_OPTIONS $LIBERTY_URL -U UA-IBM-WebSphere-Liberty-Docker -O /tmp/wlp.zip \ + && unzip -q /tmp/wlp.zip -d /opt/ibm \ + && rm /tmp/wlp.zip \ && chown -R 1001:0 /opt/ibm/wlp \ - && chmod -R g+rw /opt/ibm/wlp - -# Copy the runtime and licenses -COPY --from=getRuntime --chown=1001:0 /opt/ibm/wlp /opt/ibm/wlp -COPY --from=getRuntime /licenses /licenses - -RUN apt-get install -y --no-install-recommends openssl \ + && chmod -R g+rw /opt/ibm/wlp \ + && cp -a /opt/ibm/wlp/lafiles/. /licenses/ \ + && apt-get purge --auto-remove -y unzip \ + && apt-get purge --auto-remove -y wget \ && rm -rf /var/lib/apt/lists/* # Set Path Shortcuts diff --git a/ga/latest/kernel/Dockerfile.ubuntu.openjdk17 b/ga/latest/kernel/Dockerfile.ubuntu.openjdk17 index 7fe7d2e8c..96137b5eb 100644 --- a/ga/latest/kernel/Dockerfile.ubuntu.openjdk17 +++ b/ga/latest/kernel/Dockerfile.ubuntu.openjdk17 @@ -12,32 +12,6 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM ibm-semeru-runtimes:open-17-jre-focal AS getRuntime - -USER root - -ARG VERBOSE=false - -# Install WebSphere Liberty -ARG LIBERTY_VERSION=23.0.0.6 -ARG LIBERTY_URL -ARG DOWNLOAD_OPTIONS="" - -# If there is a local copy of the image use that instead -COPY resources/ /tmp/ - -RUN apt-get update \ - && apt-get install -y --no-install-recommends unzip wget openssl \ - && rm -rf /var/lib/apt/lists/* \ - && mkdir -p /licenses/ \ - && useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ - && LIBERTY_URL=${LIBERTY_URL:-$(wget -q -O - https://public.dhe.ibm.com/ibmdl/export/pub/software/websphere/wasdev/downloads/wlp/index.yml | grep -E "^\s*kernel:.*${LIBERTY_VERSION}\.zip" | sed -n 's/\s*kernel:\s//p' | tr -d '\r' )} \ - && if [ ! -f /tmp/wlp.zip ]; then wget $DOWNLOAD_OPTIONS $LIBERTY_URL -U UA-IBM-WebSphere-Liberty-Docker -O /tmp/wlp.zip; fi \ - && unzip -q /tmp/wlp.zip -d /opt/ibm \ - && chown -R 1001:0 /opt/ibm/wlp \ - && chmod -R g+rw /opt/ibm/wlp \ - && cp -a /opt/ibm/wlp/lafiles/. /licenses/ - FROM ibm-semeru-runtimes:open-17-jre-focal USER root @@ -94,17 +68,23 @@ RUN set -eux; \ echo "${DUMB_INIT_SHA256} */usr/bin/dumb-init" | sha256sum -c -; \ chmod +x /usr/bin/dumb-init; -# Add default user 1001 and create wlp with right user/permissions before copying -RUN useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ - && mkdir -p /opt/ibm/wlp \ +# Install WebSphere Liberty +ARG LIBERTY_URL +ARG DOWNLOAD_OPTIONS="" +RUN apt-get update \ + && apt-get install -y --no-install-recommends unzip wget \ + && rm -rf /var/lib/apt/lists/* \ + && mkdir -p /licenses/ \ + && useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ + && LIBERTY_URL=${LIBERTY_URL:-$(wget -q -O - https://public.dhe.ibm.com/ibmdl/export/pub/software/websphere/wasdev/downloads/wlp/index.yml | grep -E "^\s*kernel:.*${LIBERTY_VERSION}\.zip" | sed -n 's/\s*kernel:\s//p' | tr -d '\r' )} \ + && wget $DOWNLOAD_OPTIONS $LIBERTY_URL -U UA-IBM-WebSphere-Liberty-Docker -O /tmp/wlp.zip \ + && unzip -q /tmp/wlp.zip -d /opt/ibm \ + && rm /tmp/wlp.zip \ && chown -R 1001:0 /opt/ibm/wlp \ - && chmod -R g+rw /opt/ibm/wlp - -# Copy the runtime and licenses -COPY --from=getRuntime --chown=1001:0 /opt/ibm/wlp /opt/ibm/wlp -COPY --from=getRuntime /licenses /licenses - -RUN apt-get install -y --no-install-recommends openssl \ + && chmod -R g+rw /opt/ibm/wlp \ + && cp -a /opt/ibm/wlp/lafiles/. /licenses/ \ + && apt-get purge --auto-remove -y unzip \ + && apt-get purge --auto-remove -y wget \ && rm -rf /var/lib/apt/lists/* # Set Path Shortcuts From abd609904b6dc3b10e83390816de9b75fd6ea388 Mon Sep 17 00:00:00 2001 From: Michal Broz Date: Fri, 21 Jul 2023 08:42:50 -0500 Subject: [PATCH 03/19] add fix back in for REPOSITORIES_PROPERTIES --- ga/23.0.0.6/full/Dockerfile.ubuntu.ibmjava8 | 17 +++++++++++------ ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk11 | 17 +++++++++++------ ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk17 | 17 +++++++++++------ ga/latest/full/Dockerfile.ubuntu.ibmjava8 | 17 +++++++++++------ ga/latest/full/Dockerfile.ubuntu.openjdk11 | 17 +++++++++++------ ga/latest/full/Dockerfile.ubuntu.openjdk17 | 17 +++++++++++------ 6 files changed, 66 insertions(+), 36 deletions(-) diff --git a/ga/23.0.0.6/full/Dockerfile.ubuntu.ibmjava8 b/ga/23.0.0.6/full/Dockerfile.ubuntu.ibmjava8 index a437bca4c..229de6c9c 100644 --- a/ga/23.0.0.6/full/Dockerfile.ubuntu.ibmjava8 +++ b/ga/23.0.0.6/full/Dockerfile.ubuntu.ibmjava8 @@ -20,12 +20,17 @@ ARG VERBOSE=false ARG REPOSITORIES_PROPERTIES="" # Install the base bundle -RUN if [ ! -z $REPOSITORIES_PROPERTIES ]; then mkdir /opt/ibm/wlp/etc/ \ - && echo $REPOSITORIES_PROPERTIES > /opt/ibm/wlp/etc/repositories.properties; fi \ - && installUtility install --acceptLicense baseBundle \ - && if [ ! -z $REPOSITORIES_PROPERTIES ]; then rm /opt/ibm/wlp/etc/repositories.properties; fi \ - && rm -rf /output/workarea /output/logs \ - && find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw +RUN set -eux; \ + if [ ! -z "$REPOSITORIES_PROPERTIES" ]; then \ + mkdir /opt/ibm/wlp/etc/; \ + echo "$REPOSITORIES_PROPERTIES" > /opt/ibm/wlp/etc/repositories.properties; \ + fi; \ + installUtility install --acceptLicense baseBundle; \ + if [ ! -z "$REPOSITORIES_PROPERTIES" ]; then \ + rm /opt/ibm/wlp/etc/repositories.properties; \ + fi; \ + rm -rf /output/workarea /output/logs; \ + find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw; COPY --chown=1001:0 server.xml /config/ diff --git a/ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk11 b/ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk11 index a28e2d432..49439d852 100644 --- a/ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk11 +++ b/ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk11 @@ -20,12 +20,17 @@ ARG VERBOSE=false ARG REPOSITORIES_PROPERTIES="" # Install the base bundle -RUN if [ ! -z $REPOSITORIES_PROPERTIES ]; then mkdir /opt/ibm/wlp/etc/ \ - && echo $REPOSITORIES_PROPERTIES > /opt/ibm/wlp/etc/repositories.properties; fi \ - && installUtility install --acceptLicense baseBundle \ - && if [ ! -z $REPOSITORIES_PROPERTIES ]; then rm /opt/ibm/wlp/etc/repositories.properties; fi \ - && rm -rf /output/workarea /output/logs \ - && find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw +RUN set -eux; \ + if [ ! -z "$REPOSITORIES_PROPERTIES" ]; then \ + mkdir /opt/ibm/wlp/etc/; \ + echo "$REPOSITORIES_PROPERTIES" > /opt/ibm/wlp/etc/repositories.properties; \ + fi; \ + installUtility install --acceptLicense baseBundle; \ + if [ ! -z "$REPOSITORIES_PROPERTIES" ]; then \ + rm /opt/ibm/wlp/etc/repositories.properties; \ + fi; \ + rm -rf /output/workarea /output/logs; \ + find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw; COPY --chown=1001:0 server.xml /config/ diff --git a/ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk17 b/ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk17 index d3a5494eb..d4b622462 100644 --- a/ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk17 +++ b/ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk17 @@ -20,12 +20,17 @@ ARG VERBOSE=false ARG REPOSITORIES_PROPERTIES="" # Install the base bundle -RUN if [ ! -z $REPOSITORIES_PROPERTIES ]; then mkdir /opt/ibm/wlp/etc/ \ - && echo $REPOSITORIES_PROPERTIES > /opt/ibm/wlp/etc/repositories.properties; fi \ - && installUtility install --acceptLicense baseBundle \ - && if [ ! -z $REPOSITORIES_PROPERTIES ]; then rm /opt/ibm/wlp/etc/repositories.properties; fi \ - && rm -rf /output/workarea /output/logs \ - && find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw +RUN set -eux; \ + if [ ! -z "$REPOSITORIES_PROPERTIES" ]; then \ + mkdir /opt/ibm/wlp/etc/; \ + echo "$REPOSITORIES_PROPERTIES" > /opt/ibm/wlp/etc/repositories.properties; \ + fi; \ + installUtility install --acceptLicense baseBundle; \ + if [ ! -z "$REPOSITORIES_PROPERTIES" ]; then \ + rm /opt/ibm/wlp/etc/repositories.properties; \ + fi; \ + rm -rf /output/workarea /output/logs; \ + find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw; COPY --chown=1001:0 server.xml /config/ diff --git a/ga/latest/full/Dockerfile.ubuntu.ibmjava8 b/ga/latest/full/Dockerfile.ubuntu.ibmjava8 index a437bca4c..229de6c9c 100644 --- a/ga/latest/full/Dockerfile.ubuntu.ibmjava8 +++ b/ga/latest/full/Dockerfile.ubuntu.ibmjava8 @@ -20,12 +20,17 @@ ARG VERBOSE=false ARG REPOSITORIES_PROPERTIES="" # Install the base bundle -RUN if [ ! -z $REPOSITORIES_PROPERTIES ]; then mkdir /opt/ibm/wlp/etc/ \ - && echo $REPOSITORIES_PROPERTIES > /opt/ibm/wlp/etc/repositories.properties; fi \ - && installUtility install --acceptLicense baseBundle \ - && if [ ! -z $REPOSITORIES_PROPERTIES ]; then rm /opt/ibm/wlp/etc/repositories.properties; fi \ - && rm -rf /output/workarea /output/logs \ - && find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw +RUN set -eux; \ + if [ ! -z "$REPOSITORIES_PROPERTIES" ]; then \ + mkdir /opt/ibm/wlp/etc/; \ + echo "$REPOSITORIES_PROPERTIES" > /opt/ibm/wlp/etc/repositories.properties; \ + fi; \ + installUtility install --acceptLicense baseBundle; \ + if [ ! -z "$REPOSITORIES_PROPERTIES" ]; then \ + rm /opt/ibm/wlp/etc/repositories.properties; \ + fi; \ + rm -rf /output/workarea /output/logs; \ + find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw; COPY --chown=1001:0 server.xml /config/ diff --git a/ga/latest/full/Dockerfile.ubuntu.openjdk11 b/ga/latest/full/Dockerfile.ubuntu.openjdk11 index a28e2d432..49439d852 100644 --- a/ga/latest/full/Dockerfile.ubuntu.openjdk11 +++ b/ga/latest/full/Dockerfile.ubuntu.openjdk11 @@ -20,12 +20,17 @@ ARG VERBOSE=false ARG REPOSITORIES_PROPERTIES="" # Install the base bundle -RUN if [ ! -z $REPOSITORIES_PROPERTIES ]; then mkdir /opt/ibm/wlp/etc/ \ - && echo $REPOSITORIES_PROPERTIES > /opt/ibm/wlp/etc/repositories.properties; fi \ - && installUtility install --acceptLicense baseBundle \ - && if [ ! -z $REPOSITORIES_PROPERTIES ]; then rm /opt/ibm/wlp/etc/repositories.properties; fi \ - && rm -rf /output/workarea /output/logs \ - && find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw +RUN set -eux; \ + if [ ! -z "$REPOSITORIES_PROPERTIES" ]; then \ + mkdir /opt/ibm/wlp/etc/; \ + echo "$REPOSITORIES_PROPERTIES" > /opt/ibm/wlp/etc/repositories.properties; \ + fi; \ + installUtility install --acceptLicense baseBundle; \ + if [ ! -z "$REPOSITORIES_PROPERTIES" ]; then \ + rm /opt/ibm/wlp/etc/repositories.properties; \ + fi; \ + rm -rf /output/workarea /output/logs; \ + find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw; COPY --chown=1001:0 server.xml /config/ diff --git a/ga/latest/full/Dockerfile.ubuntu.openjdk17 b/ga/latest/full/Dockerfile.ubuntu.openjdk17 index d3a5494eb..d4b622462 100644 --- a/ga/latest/full/Dockerfile.ubuntu.openjdk17 +++ b/ga/latest/full/Dockerfile.ubuntu.openjdk17 @@ -20,12 +20,17 @@ ARG VERBOSE=false ARG REPOSITORIES_PROPERTIES="" # Install the base bundle -RUN if [ ! -z $REPOSITORIES_PROPERTIES ]; then mkdir /opt/ibm/wlp/etc/ \ - && echo $REPOSITORIES_PROPERTIES > /opt/ibm/wlp/etc/repositories.properties; fi \ - && installUtility install --acceptLicense baseBundle \ - && if [ ! -z $REPOSITORIES_PROPERTIES ]; then rm /opt/ibm/wlp/etc/repositories.properties; fi \ - && rm -rf /output/workarea /output/logs \ - && find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw +RUN set -eux; \ + if [ ! -z "$REPOSITORIES_PROPERTIES" ]; then \ + mkdir /opt/ibm/wlp/etc/; \ + echo "$REPOSITORIES_PROPERTIES" > /opt/ibm/wlp/etc/repositories.properties; \ + fi; \ + installUtility install --acceptLicense baseBundle; \ + if [ ! -z "$REPOSITORIES_PROPERTIES" ]; then \ + rm /opt/ibm/wlp/etc/repositories.properties; \ + fi; \ + rm -rf /output/workarea /output/logs; \ + find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw; COPY --chown=1001:0 server.xml /config/ From 59d9ef54a901fd791c57a662c60f4497180685f8 Mon Sep 17 00:00:00 2001 From: Michal Broz Date: Fri, 21 Jul 2023 10:36:06 -0500 Subject: [PATCH 04/19] fix 23.0.0.6 full FROMs --- ga/23.0.0.6/full/Dockerfile.ubuntu.ibmjava8 | 2 +- ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk11 | 2 +- ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk17 | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/ga/23.0.0.6/full/Dockerfile.ubuntu.ibmjava8 b/ga/23.0.0.6/full/Dockerfile.ubuntu.ibmjava8 index 229de6c9c..616d74d84 100644 --- a/ga/23.0.0.6/full/Dockerfile.ubuntu.ibmjava8 +++ b/ga/23.0.0.6/full/Dockerfile.ubuntu.ibmjava8 @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM websphere-liberty:kernel-java8-ibmjava +FROM websphere-liberty:23.0.0.6-kernel-java8-ibmjava USER root diff --git a/ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk11 b/ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk11 index 49439d852..9f52f30b8 100644 --- a/ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk11 +++ b/ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk11 @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM websphere-liberty:kernel-java11-openj9 +FROM websphere-liberty:23.0.0.6-kernel-java11-openj9 USER root diff --git a/ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk17 b/ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk17 index d4b622462..4d269dfdc 100644 --- a/ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk17 +++ b/ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk17 @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM websphere-liberty:kernel-java17-openj9 +FROM websphere-liberty:23.0.0.6-kernel-java17-openj9 USER root From 172e14e95767f33978cb83c2bd3732f44ffcebe5 Mon Sep 17 00:00:00 2001 From: Younes Manton <926840+ymanton@users.noreply.github.com> Date: Fri, 21 Jul 2023 14:48:28 -0400 Subject: [PATCH 05/19] Fail if server cannot start when populating SCC (#522) If the server fails to start when populating the SCC we should gracefully fail the build. Because the populate_scc.sh script sets the -e shell option, the shell will exit if any command returns non-zero, except in certain cases. The populate_scc.sh script starts and stops the server in a compound expression using &&, which is one such case where a non-zero return from `server start` will be ignored. Executing `server start` and `server stop` separately fixes this and has the desired behaviour; if the server fails to start execution will stop and the build will fail, rather than continuing on and leading to undefined behaviour. Signed-off-by: Younes Manton --- ga/23.0.0.3/kernel/helpers/build/populate_scc.sh | 6 ++++-- ga/23.0.0.6/kernel/helpers/build/populate_scc.sh | 6 ++++-- ga/latest/kernel/helpers/build/populate_scc.sh | 6 ++++-- 3 files changed, 12 insertions(+), 6 deletions(-) diff --git a/ga/23.0.0.3/kernel/helpers/build/populate_scc.sh b/ga/23.0.0.3/kernel/helpers/build/populate_scc.sh index 8f65ec392..3c07a4e92 100755 --- a/ga/23.0.0.3/kernel/helpers/build/populate_scc.sh +++ b/ga/23.0.0.3/kernel/helpers/build/populate_scc.sh @@ -97,7 +97,8 @@ if [ $TRIM_SCC == yes ] then echo "Calculating SCC layer upper bound, starting with initial size $SCC_SIZE." # Populate the newly created class cache layer. - /opt/ibm/wlp/bin/server start && /opt/ibm/wlp/bin/server stop + /opt/ibm/wlp/bin/server start + /opt/ibm/wlp/bin/server stop # Find out how full it is. FULL=`( java $PRINT_LAYER_STATS || true ) 2>&1 | awk '/^Cache is [0-9.]*% .*full/ {print substr($3, 1, length($3)-1)}'` echo "SCC layer is $FULL% full. Destroying layer." @@ -120,7 +121,8 @@ fi # Server start/stop to populate the /output/workarea and make subsequent server starts faster. for ((i=0; i<$ITERATIONS; i++)) do - /opt/ibm/wlp/bin/server start && /opt/ibm/wlp/bin/server stop + /opt/ibm/wlp/bin/server start + /opt/ibm/wlp/bin/server stop done # restore umask diff --git a/ga/23.0.0.6/kernel/helpers/build/populate_scc.sh b/ga/23.0.0.6/kernel/helpers/build/populate_scc.sh index 8f65ec392..3c07a4e92 100755 --- a/ga/23.0.0.6/kernel/helpers/build/populate_scc.sh +++ b/ga/23.0.0.6/kernel/helpers/build/populate_scc.sh @@ -97,7 +97,8 @@ if [ $TRIM_SCC == yes ] then echo "Calculating SCC layer upper bound, starting with initial size $SCC_SIZE." # Populate the newly created class cache layer. - /opt/ibm/wlp/bin/server start && /opt/ibm/wlp/bin/server stop + /opt/ibm/wlp/bin/server start + /opt/ibm/wlp/bin/server stop # Find out how full it is. FULL=`( java $PRINT_LAYER_STATS || true ) 2>&1 | awk '/^Cache is [0-9.]*% .*full/ {print substr($3, 1, length($3)-1)}'` echo "SCC layer is $FULL% full. Destroying layer." @@ -120,7 +121,8 @@ fi # Server start/stop to populate the /output/workarea and make subsequent server starts faster. for ((i=0; i<$ITERATIONS; i++)) do - /opt/ibm/wlp/bin/server start && /opt/ibm/wlp/bin/server stop + /opt/ibm/wlp/bin/server start + /opt/ibm/wlp/bin/server stop done # restore umask diff --git a/ga/latest/kernel/helpers/build/populate_scc.sh b/ga/latest/kernel/helpers/build/populate_scc.sh index 8f65ec392..3c07a4e92 100755 --- a/ga/latest/kernel/helpers/build/populate_scc.sh +++ b/ga/latest/kernel/helpers/build/populate_scc.sh @@ -97,7 +97,8 @@ if [ $TRIM_SCC == yes ] then echo "Calculating SCC layer upper bound, starting with initial size $SCC_SIZE." # Populate the newly created class cache layer. - /opt/ibm/wlp/bin/server start && /opt/ibm/wlp/bin/server stop + /opt/ibm/wlp/bin/server start + /opt/ibm/wlp/bin/server stop # Find out how full it is. FULL=`( java $PRINT_LAYER_STATS || true ) 2>&1 | awk '/^Cache is [0-9.]*% .*full/ {print substr($3, 1, length($3)-1)}'` echo "SCC layer is $FULL% full. Destroying layer." @@ -120,7 +121,8 @@ fi # Server start/stop to populate the /output/workarea and make subsequent server starts faster. for ((i=0; i<$ITERATIONS; i++)) do - /opt/ibm/wlp/bin/server start && /opt/ibm/wlp/bin/server stop + /opt/ibm/wlp/bin/server start + /opt/ibm/wlp/bin/server stop done # restore umask From 87b8f1b06e90dbe3d12af09e5afa775e26679aad Mon Sep 17 00:00:00 2001 From: Michal Broz Date: Fri, 21 Jul 2023 15:49:15 -0500 Subject: [PATCH 06/19] install/update openssl for ubuntu images --- ga/23.0.0.6/kernel/Dockerfile.ubuntu.openjdk11 | 2 +- ga/23.0.0.6/kernel/Dockerfile.ubuntu.openjdk17 | 2 +- ga/latest/kernel/Dockerfile.ubuntu.openjdk11 | 2 +- ga/latest/kernel/Dockerfile.ubuntu.openjdk17 | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/ga/23.0.0.6/kernel/Dockerfile.ubuntu.openjdk11 b/ga/23.0.0.6/kernel/Dockerfile.ubuntu.openjdk11 index 27546784c..968685e4b 100644 --- a/ga/23.0.0.6/kernel/Dockerfile.ubuntu.openjdk11 +++ b/ga/23.0.0.6/kernel/Dockerfile.ubuntu.openjdk11 @@ -72,7 +72,7 @@ RUN set -eux; \ ARG LIBERTY_URL ARG DOWNLOAD_OPTIONS="" RUN apt-get update \ - && apt-get install -y --no-install-recommends unzip wget \ + && apt-get install -y --no-install-recommends unzip openssl wget \ && rm -rf /var/lib/apt/lists/* \ && mkdir -p /licenses/ \ && useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ diff --git a/ga/23.0.0.6/kernel/Dockerfile.ubuntu.openjdk17 b/ga/23.0.0.6/kernel/Dockerfile.ubuntu.openjdk17 index 96137b5eb..6c75686c2 100644 --- a/ga/23.0.0.6/kernel/Dockerfile.ubuntu.openjdk17 +++ b/ga/23.0.0.6/kernel/Dockerfile.ubuntu.openjdk17 @@ -72,7 +72,7 @@ RUN set -eux; \ ARG LIBERTY_URL ARG DOWNLOAD_OPTIONS="" RUN apt-get update \ - && apt-get install -y --no-install-recommends unzip wget \ + && apt-get install -y --no-install-recommends unzip openssl wget \ && rm -rf /var/lib/apt/lists/* \ && mkdir -p /licenses/ \ && useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ diff --git a/ga/latest/kernel/Dockerfile.ubuntu.openjdk11 b/ga/latest/kernel/Dockerfile.ubuntu.openjdk11 index 27546784c..968685e4b 100644 --- a/ga/latest/kernel/Dockerfile.ubuntu.openjdk11 +++ b/ga/latest/kernel/Dockerfile.ubuntu.openjdk11 @@ -72,7 +72,7 @@ RUN set -eux; \ ARG LIBERTY_URL ARG DOWNLOAD_OPTIONS="" RUN apt-get update \ - && apt-get install -y --no-install-recommends unzip wget \ + && apt-get install -y --no-install-recommends unzip openssl wget \ && rm -rf /var/lib/apt/lists/* \ && mkdir -p /licenses/ \ && useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ diff --git a/ga/latest/kernel/Dockerfile.ubuntu.openjdk17 b/ga/latest/kernel/Dockerfile.ubuntu.openjdk17 index 96137b5eb..6c75686c2 100644 --- a/ga/latest/kernel/Dockerfile.ubuntu.openjdk17 +++ b/ga/latest/kernel/Dockerfile.ubuntu.openjdk17 @@ -72,7 +72,7 @@ RUN set -eux; \ ARG LIBERTY_URL ARG DOWNLOAD_OPTIONS="" RUN apt-get update \ - && apt-get install -y --no-install-recommends unzip wget \ + && apt-get install -y --no-install-recommends unzip openssl wget \ && rm -rf /var/lib/apt/lists/* \ && mkdir -p /licenses/ \ && useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ From 6dd8b6cfd9b80860001ccba31f2c27508f27bf45 Mon Sep 17 00:00:00 2001 From: Leo Christy Jesuraj Date: Fri, 21 Jul 2023 18:08:19 -0400 Subject: [PATCH 07/19] Remove root user from full images and use chown when copying files (#524) Signed-off-by: Leo Christy Jesuraj --- ga/23.0.0.6/full/Dockerfile.ubi.ibmjava8 | 4 +--- ga/23.0.0.6/full/Dockerfile.ubi.openjdk11 | 4 +--- ga/23.0.0.6/full/Dockerfile.ubi.openjdk17 | 4 +--- ga/23.0.0.6/full/Dockerfile.ubi.openjdk8 | 4 +--- ga/23.0.0.6/full/Dockerfile.ubuntu.ibmjava8 | 2 -- ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk11 | 2 -- ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk17 | 2 -- ga/latest/full/Dockerfile.ubi.ibmjava8 | 4 +--- ga/latest/full/Dockerfile.ubi.openjdk11 | 4 +--- ga/latest/full/Dockerfile.ubi.openjdk17 | 4 +--- ga/latest/full/Dockerfile.ubi.openjdk8 | 4 +--- ga/latest/full/Dockerfile.ubuntu.ibmjava8 | 2 -- ga/latest/full/Dockerfile.ubuntu.openjdk11 | 2 -- ga/latest/full/Dockerfile.ubuntu.openjdk17 | 2 -- 14 files changed, 8 insertions(+), 36 deletions(-) diff --git a/ga/23.0.0.6/full/Dockerfile.ubi.ibmjava8 b/ga/23.0.0.6/full/Dockerfile.ubi.ibmjava8 index 56333ba65..117065353 100644 --- a/ga/23.0.0.6/full/Dockerfile.ubi.ibmjava8 +++ b/ga/23.0.0.6/full/Dockerfile.ubi.ibmjava8 @@ -15,8 +15,6 @@ ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:23.0.0.6-kernel-java8-ibmjava-ubi FROM $PARENT_IMAGE AS installBundle -USER root - ARG VERBOSE=false ARG REPOSITORIES_PROPERTIES="" @@ -43,7 +41,7 @@ FROM $PARENT_IMAGE ARG VERBOSE=false # Copy the runtime -COPY --from=installBundle /opt/ibm/wlp /opt/ibm/wlp +COPY --from=installBundle --chown=1001:0 /opt/ibm/wlp /opt/ibm/wlp COPY --chown=1001:0 server.xml /config/ diff --git a/ga/23.0.0.6/full/Dockerfile.ubi.openjdk11 b/ga/23.0.0.6/full/Dockerfile.ubi.openjdk11 index ccd5142e6..6327e6463 100644 --- a/ga/23.0.0.6/full/Dockerfile.ubi.openjdk11 +++ b/ga/23.0.0.6/full/Dockerfile.ubi.openjdk11 @@ -15,8 +15,6 @@ ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:23.0.0.6-kernel-java11-openj9-ubi FROM $PARENT_IMAGE AS installBundle -USER root - ARG VERBOSE=false ARG REPOSITORIES_PROPERTIES="" @@ -43,7 +41,7 @@ FROM $PARENT_IMAGE ARG VERBOSE=false # Copy the runtime -COPY --from=installBundle /opt/ibm/wlp /opt/ibm/wlp +COPY --from=installBundle --chown=1001:0 /opt/ibm/wlp /opt/ibm/wlp COPY --chown=1001:0 server.xml /config/ diff --git a/ga/23.0.0.6/full/Dockerfile.ubi.openjdk17 b/ga/23.0.0.6/full/Dockerfile.ubi.openjdk17 index 90c63a789..8a3db2b93 100644 --- a/ga/23.0.0.6/full/Dockerfile.ubi.openjdk17 +++ b/ga/23.0.0.6/full/Dockerfile.ubi.openjdk17 @@ -15,8 +15,6 @@ ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:23.0.0.6-kernel-java17-openj9-ubi FROM $PARENT_IMAGE AS installBundle -USER root - ARG VERBOSE=false ARG REPOSITORIES_PROPERTIES="" @@ -43,7 +41,7 @@ FROM $PARENT_IMAGE ARG VERBOSE=false # Copy the runtime -COPY --from=installBundle /opt/ibm/wlp /opt/ibm/wlp +COPY --from=installBundle --chown=1001:0 /opt/ibm/wlp /opt/ibm/wlp COPY --chown=1001:0 server.xml /config/ diff --git a/ga/23.0.0.6/full/Dockerfile.ubi.openjdk8 b/ga/23.0.0.6/full/Dockerfile.ubi.openjdk8 index 2ce3dc275..41abc3a15 100644 --- a/ga/23.0.0.6/full/Dockerfile.ubi.openjdk8 +++ b/ga/23.0.0.6/full/Dockerfile.ubi.openjdk8 @@ -15,8 +15,6 @@ ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:23.0.0.6-kernel-java8-openj9-ubi FROM $PARENT_IMAGE AS installBundle -USER root - ARG VERBOSE=false ARG REPOSITORIES_PROPERTIES="" @@ -43,7 +41,7 @@ FROM $PARENT_IMAGE ARG VERBOSE=false # Copy the runtime -COPY --from=installBundle /opt/ibm/wlp /opt/ibm/wlp +COPY --from=installBundle --chown=1001:0 /opt/ibm/wlp /opt/ibm/wlp COPY --chown=1001:0 server.xml /config/ diff --git a/ga/23.0.0.6/full/Dockerfile.ubuntu.ibmjava8 b/ga/23.0.0.6/full/Dockerfile.ubuntu.ibmjava8 index 616d74d84..9eb122917 100644 --- a/ga/23.0.0.6/full/Dockerfile.ubuntu.ibmjava8 +++ b/ga/23.0.0.6/full/Dockerfile.ubuntu.ibmjava8 @@ -14,8 +14,6 @@ FROM websphere-liberty:23.0.0.6-kernel-java8-ibmjava -USER root - ARG VERBOSE=false ARG REPOSITORIES_PROPERTIES="" diff --git a/ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk11 b/ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk11 index 9f52f30b8..b1097a11b 100644 --- a/ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk11 +++ b/ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk11 @@ -14,8 +14,6 @@ FROM websphere-liberty:23.0.0.6-kernel-java11-openj9 -USER root - ARG VERBOSE=false ARG REPOSITORIES_PROPERTIES="" diff --git a/ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk17 b/ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk17 index 4d269dfdc..f6a03f276 100644 --- a/ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk17 +++ b/ga/23.0.0.6/full/Dockerfile.ubuntu.openjdk17 @@ -14,8 +14,6 @@ FROM websphere-liberty:23.0.0.6-kernel-java17-openj9 -USER root - ARG VERBOSE=false ARG REPOSITORIES_PROPERTIES="" diff --git a/ga/latest/full/Dockerfile.ubi.ibmjava8 b/ga/latest/full/Dockerfile.ubi.ibmjava8 index 2a2aef089..8323de579 100644 --- a/ga/latest/full/Dockerfile.ubi.ibmjava8 +++ b/ga/latest/full/Dockerfile.ubi.ibmjava8 @@ -15,8 +15,6 @@ ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:kernel-java8-ibmjava-ubi FROM $PARENT_IMAGE AS installBundle -USER root - ARG VERBOSE=false ARG REPOSITORIES_PROPERTIES="" @@ -43,7 +41,7 @@ FROM $PARENT_IMAGE ARG VERBOSE=false # Copy the runtime -COPY --from=installBundle /opt/ibm/wlp /opt/ibm/wlp +COPY --from=installBundle --chown=1001:0 /opt/ibm/wlp /opt/ibm/wlp COPY --chown=1001:0 server.xml /config/ diff --git a/ga/latest/full/Dockerfile.ubi.openjdk11 b/ga/latest/full/Dockerfile.ubi.openjdk11 index 79f2900b0..8669e3adf 100644 --- a/ga/latest/full/Dockerfile.ubi.openjdk11 +++ b/ga/latest/full/Dockerfile.ubi.openjdk11 @@ -15,8 +15,6 @@ ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:kernel-java11-openj9-ubi FROM $PARENT_IMAGE AS installBundle -USER root - ARG VERBOSE=false ARG REPOSITORIES_PROPERTIES="" @@ -43,7 +41,7 @@ FROM $PARENT_IMAGE ARG VERBOSE=false # Copy the runtime -COPY --from=installBundle /opt/ibm/wlp /opt/ibm/wlp +COPY --from=installBundle --chown=1001:0 /opt/ibm/wlp /opt/ibm/wlp COPY --chown=1001:0 server.xml /config/ diff --git a/ga/latest/full/Dockerfile.ubi.openjdk17 b/ga/latest/full/Dockerfile.ubi.openjdk17 index dc91e1978..e38227406 100644 --- a/ga/latest/full/Dockerfile.ubi.openjdk17 +++ b/ga/latest/full/Dockerfile.ubi.openjdk17 @@ -15,8 +15,6 @@ ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:kernel-java17-openj9-ubi FROM $PARENT_IMAGE AS installBundle -USER root - ARG VERBOSE=false ARG REPOSITORIES_PROPERTIES="" @@ -43,7 +41,7 @@ FROM $PARENT_IMAGE ARG VERBOSE=false # Copy the runtime -COPY --from=installBundle /opt/ibm/wlp /opt/ibm/wlp +COPY --from=installBundle --chown=1001:0 /opt/ibm/wlp /opt/ibm/wlp COPY --chown=1001:0 server.xml /config/ diff --git a/ga/latest/full/Dockerfile.ubi.openjdk8 b/ga/latest/full/Dockerfile.ubi.openjdk8 index 1d700de48..0081f5719 100644 --- a/ga/latest/full/Dockerfile.ubi.openjdk8 +++ b/ga/latest/full/Dockerfile.ubi.openjdk8 @@ -15,8 +15,6 @@ ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:kernel-java8-openj9-ubi FROM $PARENT_IMAGE AS installBundle -USER root - ARG VERBOSE=false ARG REPOSITORIES_PROPERTIES="" @@ -43,7 +41,7 @@ FROM $PARENT_IMAGE ARG VERBOSE=false # Copy the runtime -COPY --from=installBundle /opt/ibm/wlp /opt/ibm/wlp +COPY --from=installBundle --chown=1001:0 /opt/ibm/wlp /opt/ibm/wlp COPY --chown=1001:0 server.xml /config/ diff --git a/ga/latest/full/Dockerfile.ubuntu.ibmjava8 b/ga/latest/full/Dockerfile.ubuntu.ibmjava8 index 229de6c9c..c301dfec2 100644 --- a/ga/latest/full/Dockerfile.ubuntu.ibmjava8 +++ b/ga/latest/full/Dockerfile.ubuntu.ibmjava8 @@ -14,8 +14,6 @@ FROM websphere-liberty:kernel-java8-ibmjava -USER root - ARG VERBOSE=false ARG REPOSITORIES_PROPERTIES="" diff --git a/ga/latest/full/Dockerfile.ubuntu.openjdk11 b/ga/latest/full/Dockerfile.ubuntu.openjdk11 index 49439d852..305136390 100644 --- a/ga/latest/full/Dockerfile.ubuntu.openjdk11 +++ b/ga/latest/full/Dockerfile.ubuntu.openjdk11 @@ -14,8 +14,6 @@ FROM websphere-liberty:kernel-java11-openj9 -USER root - ARG VERBOSE=false ARG REPOSITORIES_PROPERTIES="" diff --git a/ga/latest/full/Dockerfile.ubuntu.openjdk17 b/ga/latest/full/Dockerfile.ubuntu.openjdk17 index d4b622462..58d75c5a0 100644 --- a/ga/latest/full/Dockerfile.ubuntu.openjdk17 +++ b/ga/latest/full/Dockerfile.ubuntu.openjdk17 @@ -14,8 +14,6 @@ FROM websphere-liberty:kernel-java17-openj9 -USER root - ARG VERBOSE=false ARG REPOSITORIES_PROPERTIES="" From 1dad2061fd55be322bf8189c0417c60abb75cce8 Mon Sep 17 00:00:00 2001 From: Ian Lewis Date: Mon, 24 Jul 2023 14:50:14 +0100 Subject: [PATCH 08/19] Update from focal to jammy (#521) * Fix bugs/formating in verify script * Move from Ubuntu 20.04 (focal) to 22.04 (jammy) --- ga/latest/kernel/Dockerfile.ubuntu.openjdk11 | 2 +- ga/latest/kernel/Dockerfile.ubuntu.openjdk17 | 2 +- test/verify.sh | 6 +++--- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/ga/latest/kernel/Dockerfile.ubuntu.openjdk11 b/ga/latest/kernel/Dockerfile.ubuntu.openjdk11 index 968685e4b..1314c7a1e 100644 --- a/ga/latest/kernel/Dockerfile.ubuntu.openjdk11 +++ b/ga/latest/kernel/Dockerfile.ubuntu.openjdk11 @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM ibm-semeru-runtimes:open-11-jre-focal +FROM ibm-semeru-runtimes:open-11-jre-jammy USER root diff --git a/ga/latest/kernel/Dockerfile.ubuntu.openjdk17 b/ga/latest/kernel/Dockerfile.ubuntu.openjdk17 index 6c75686c2..eb30ccca7 100644 --- a/ga/latest/kernel/Dockerfile.ubuntu.openjdk17 +++ b/ga/latest/kernel/Dockerfile.ubuntu.openjdk17 @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM ibm-semeru-runtimes:open-17-jre-focal +FROM ibm-semeru-runtimes:open-17-jre-jammy USER root diff --git a/test/verify.sh b/test/verify.sh index 045170066..b82aedaae 100755 --- a/test/verify.sh +++ b/test/verify.sh @@ -43,7 +43,7 @@ main () { local tests=$(declare -F | cut -d" " -f3 | grep "^test") echo "****** Testing ${IMAGE}..." - for name in "${tests}"; do + for name in $tests; do timestamp=$(date '+%Y/%m/%d %H:%M:%S') echo "${timestamp} *** ${name} - Executing" eval "${name}" @@ -99,9 +99,9 @@ testLibertyStopsAndRestarts() if [ "$1" == "OpenShift" ]; then timestamp=$(date '+%Y/%m/%d %H:%M:%S') echo "$timestamp *** testLibertyStopsAndRestarts on OpenShift" - cid=$(docker run -d -u 1001:0 $IMAGE) + local cid=$(docker run -d -u 1001:0 $IMAGE) else - local cid=$(docker run -d $IMAGE) + local cid=$(docker run -d $IMAGE) fi echo "Waiting for server to start..." waitForServerStart "${cid}" \ From f36cfadf7b4fa2cf9fdfb4d41dd19feb1492beae Mon Sep 17 00:00:00 2001 From: Leo Christy Jesuraj Date: Mon, 24 Jul 2023 13:55:47 -0400 Subject: [PATCH 09/19] Change /liberty symlink from /opt/ibm to /opt/ibm/wlp (#525) Signed-off-by: Leo Christy Jesuraj --- ga/latest/kernel/Dockerfile.ubi.ibmjava8 | 2 +- ga/latest/kernel/Dockerfile.ubi.openjdk11 | 2 +- ga/latest/kernel/Dockerfile.ubi.openjdk17 | 2 +- ga/latest/kernel/Dockerfile.ubi.openjdk8 | 2 +- ga/latest/kernel/Dockerfile.ubuntu.ibmjava8 | 2 +- ga/latest/kernel/Dockerfile.ubuntu.openjdk11 | 2 +- ga/latest/kernel/Dockerfile.ubuntu.openjdk17 | 2 +- 7 files changed, 7 insertions(+), 7 deletions(-) diff --git a/ga/latest/kernel/Dockerfile.ubi.ibmjava8 b/ga/latest/kernel/Dockerfile.ubi.ibmjava8 index 74d122601..0b4a832e9 100644 --- a/ga/latest/kernel/Dockerfile.ubi.ibmjava8 +++ b/ga/latest/kernel/Dockerfile.ubi.ibmjava8 @@ -135,7 +135,7 @@ RUN mkdir /logs \ && rm -rf /output \ && ln -s $WLP_OUTPUT_DIR/defaultServer /output \ && ln -s /opt/ibm/wlp/usr/servers/defaultServer /config \ - && ln -s /opt/ibm /liberty \ + && ln -s /opt/ibm/wlp /liberty \ && ln -s /opt/ibm/fixes /fixes \ && ln -s /opt/ibm/wlp/usr/shared/resources/lib.index.cache /lib.index.cache \ && mkdir -p /config/configDropins/defaults \ diff --git a/ga/latest/kernel/Dockerfile.ubi.openjdk11 b/ga/latest/kernel/Dockerfile.ubi.openjdk11 index 9a1edc530..81feb104c 100644 --- a/ga/latest/kernel/Dockerfile.ubi.openjdk11 +++ b/ga/latest/kernel/Dockerfile.ubi.openjdk11 @@ -135,7 +135,7 @@ RUN mkdir /logs \ && rm -rf /output \ && ln -s $WLP_OUTPUT_DIR/defaultServer /output \ && ln -s /opt/ibm/wlp/usr/servers/defaultServer /config \ - && ln -s /opt/ibm /liberty \ + && ln -s /opt/ibm/wlp /liberty \ && ln -s /opt/ibm/fixes /fixes \ && ln -s /opt/ibm/wlp/usr/shared/resources/lib.index.cache /lib.index.cache \ && mkdir -p /config/configDropins/defaults \ diff --git a/ga/latest/kernel/Dockerfile.ubi.openjdk17 b/ga/latest/kernel/Dockerfile.ubi.openjdk17 index 2afe4dcd4..be47a9aa2 100644 --- a/ga/latest/kernel/Dockerfile.ubi.openjdk17 +++ b/ga/latest/kernel/Dockerfile.ubi.openjdk17 @@ -135,7 +135,7 @@ RUN mkdir /logs \ && rm -rf /output \ && ln -s $WLP_OUTPUT_DIR/defaultServer /output \ && ln -s /opt/ibm/wlp/usr/servers/defaultServer /config \ - && ln -s /opt/ibm /liberty \ + && ln -s /opt/ibm/wlp /liberty \ && ln -s /opt/ibm/fixes /fixes \ && ln -s /opt/ibm/wlp/usr/shared/resources/lib.index.cache /lib.index.cache \ && mkdir -p /config/configDropins/defaults \ diff --git a/ga/latest/kernel/Dockerfile.ubi.openjdk8 b/ga/latest/kernel/Dockerfile.ubi.openjdk8 index bd4740e22..ef3b64d27 100644 --- a/ga/latest/kernel/Dockerfile.ubi.openjdk8 +++ b/ga/latest/kernel/Dockerfile.ubi.openjdk8 @@ -135,7 +135,7 @@ RUN mkdir /logs \ && rm -rf /output \ && ln -s $WLP_OUTPUT_DIR/defaultServer /output \ && ln -s /opt/ibm/wlp/usr/servers/defaultServer /config \ - && ln -s /opt/ibm /liberty \ + && ln -s /opt/ibm/wlp /liberty \ && ln -s /opt/ibm/fixes /fixes \ && ln -s /opt/ibm/wlp/usr/shared/resources/lib.index.cache /lib.index.cache \ && mkdir -p /config/configDropins/defaults \ diff --git a/ga/latest/kernel/Dockerfile.ubuntu.ibmjava8 b/ga/latest/kernel/Dockerfile.ubuntu.ibmjava8 index 1b3b88a7e..18c859d77 100644 --- a/ga/latest/kernel/Dockerfile.ubuntu.ibmjava8 +++ b/ga/latest/kernel/Dockerfile.ubuntu.ibmjava8 @@ -116,7 +116,7 @@ RUN mkdir /logs \ && rm -rf /output \ && ln -s $WLP_OUTPUT_DIR/defaultServer /output \ && ln -s /opt/ibm/wlp/usr/servers/defaultServer /config \ - && ln -s /opt/ibm /liberty \ + && ln -s /opt/ibm/wlp /liberty \ && ln -s /opt/ibm/fixes /fixes \ && ln -s /opt/ibm/wlp/usr/shared/resources/lib.index.cache /lib.index.cache \ && mkdir -p /config/configDropins/defaults \ diff --git a/ga/latest/kernel/Dockerfile.ubuntu.openjdk11 b/ga/latest/kernel/Dockerfile.ubuntu.openjdk11 index 1314c7a1e..5869604de 100644 --- a/ga/latest/kernel/Dockerfile.ubuntu.openjdk11 +++ b/ga/latest/kernel/Dockerfile.ubuntu.openjdk11 @@ -111,7 +111,7 @@ RUN mkdir /logs \ && rm -rf /output \ && ln -s $WLP_OUTPUT_DIR/defaultServer /output \ && ln -s /opt/ibm/wlp/usr/servers/defaultServer /config \ - && ln -s /opt/ibm /liberty \ + && ln -s /opt/ibm/wlp /liberty \ && ln -s /opt/ibm/fixes /fixes \ && ln -s /opt/ibm/wlp/usr/shared/resources/lib.index.cache /lib.index.cache \ && mkdir -p /config/configDropins/defaults \ diff --git a/ga/latest/kernel/Dockerfile.ubuntu.openjdk17 b/ga/latest/kernel/Dockerfile.ubuntu.openjdk17 index eb30ccca7..c266368f0 100644 --- a/ga/latest/kernel/Dockerfile.ubuntu.openjdk17 +++ b/ga/latest/kernel/Dockerfile.ubuntu.openjdk17 @@ -111,7 +111,7 @@ RUN mkdir /logs \ && rm -rf /output \ && ln -s $WLP_OUTPUT_DIR/defaultServer /output \ && ln -s /opt/ibm/wlp/usr/servers/defaultServer /config \ - && ln -s /opt/ibm /liberty \ + && ln -s /opt/ibm/wlp /liberty \ && ln -s /opt/ibm/fixes /fixes \ && ln -s /opt/ibm/wlp/usr/shared/resources/lib.index.cache /lib.index.cache \ && mkdir -p /config/configDropins/defaults \ From 23743f4305c227b639ea89ffa682b1e5fc0b963b Mon Sep 17 00:00:00 2001 From: Wendy Raschke Date: Tue, 11 Jul 2023 11:05:05 -0700 Subject: [PATCH 10/19] Updates for the release of 23.0.0.7 --- ga/23.0.0.7/README.md | 6 + ga/23.0.0.7/full/Dockerfile.ubi.ibmjava8 | 53 +++++ ga/23.0.0.7/full/Dockerfile.ubi.openjdk11 | 53 +++++ ga/23.0.0.7/full/Dockerfile.ubi.openjdk17 | 53 +++++ ga/23.0.0.7/full/Dockerfile.ubi.openjdk8 | 53 +++++ ga/23.0.0.7/full/Dockerfile.ubuntu.ibmjava8 | 49 ++++ ga/23.0.0.7/full/Dockerfile.ubuntu.openjdk11 | 51 ++++ ga/23.0.0.7/full/Dockerfile.ubuntu.openjdk17 | 51 ++++ ga/23.0.0.7/full/README.md | 7 + ga/23.0.0.7/full/server.xml | 36 +++ ga/23.0.0.7/images.txt | 18 ++ ga/23.0.0.7/kernel/Dockerfile.ubi.ibmjava8 | 175 ++++++++++++++ ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk11 | 175 ++++++++++++++ ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk17 | 175 ++++++++++++++ ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk8 | 175 ++++++++++++++ ga/23.0.0.7/kernel/Dockerfile.ubuntu.ibmjava8 | 175 ++++++++++++++ .../kernel/Dockerfile.ubuntu.openjdk11 | 171 ++++++++++++++ .../kernel/Dockerfile.ubuntu.openjdk17 | 171 ++++++++++++++ ga/23.0.0.7/kernel/NOTICES | 72 ++++++ ga/23.0.0.7/kernel/README.md | 9 + ga/23.0.0.7/kernel/fixes/.gitkeep | 2 + .../kernel/helpers/build/checkpoint.sh | 13 ++ .../hazelcast-client.xml | 16 ++ .../hazelcast-embedded.xml | 19 ++ .../hazelcast-sessioncache-config.xml | 8 + .../hazelcast-sessioncache.xml | 11 + .../configuration_snippets/http-endpoint.xml | 5 + .../http-ssl-endpoint.xml | 6 + .../configuration_snippets/iiop-endpoint.xml | 5 + .../iiop-ssl-endpoint.xml | 8 + .../infinispan-client-sessioncache-config.xml | 16 ++ .../infinispan-client-sessioncache.xml | 19 ++ .../configuration_snippets/jms-endpoint.xml | 5 + .../jms-ssl-endpoint.xml | 5 + .../build/configuration_snippets/keystore.xml | 3 + .../mp-health-check.xml | 6 + .../configuration_snippets/mp-monitoring.xml | 9 + .../configuration_snippets/oidc-config.xml | 8 + .../build/configuration_snippets/oidc.xml | 6 + .../sessioncache-features.xml | 5 + .../configuration_snippets/sso-facebook.xml | 19 ++ .../configuration_snippets/sso-features.xml | 7 + .../configuration_snippets/sso-github.xml | 24 ++ .../configuration_snippets/sso-google.xml | 19 ++ .../configuration_snippets/sso-linkedin.xml | 19 ++ .../configuration_snippets/sso-oauth2.xml | 51 ++++ .../build/configuration_snippets/sso-oidc.xml | 38 +++ .../configuration_snippets/sso-twitter.xml | 17 ++ .../build/configuration_snippets/tls.xml | 5 + .../configuration_snippets/trustDefault.xml | 4 + .../configuration_snippets/truststore.xml | 5 + ga/23.0.0.7/kernel/helpers/build/configure.sh | 219 ++++++++++++++++++ ga/23.0.0.7/kernel/helpers/build/features.sh | 48 ++++ .../helpers/build/infinispan-client-setup.sh | 35 +++ .../build/internal/features-installed.sh | 9 + ga/23.0.0.7/kernel/helpers/build/pidplus.sh | 6 + .../kernel/helpers/build/populate_scc.sh | 138 +++++++++++ .../kernel/helpers/runtime/docker-server.sh | 159 +++++++++++++ .../kernel/helpers/runtime/restore-server.sh | 6 + ga/23.0.0.7/oidcProvider/Dockerfile | 32 +++ ga/23.0.0.7/oidcProvider/Dockerfile.java11 | 32 +++ ga/23.0.0.7/oidcProvider/README.md | 7 + ga/23.0.0.7/oidcProvider/server.xml | 143 ++++++++++++ ga/latest/kernel/Dockerfile.ubi.ibmjava8 | 6 +- ga/latest/kernel/Dockerfile.ubi.openjdk11 | 6 +- ga/latest/kernel/Dockerfile.ubi.openjdk17 | 6 +- ga/latest/kernel/Dockerfile.ubi.openjdk8 | 6 +- ga/latest/kernel/Dockerfile.ubuntu.ibmjava8 | 5 +- ga/latest/kernel/Dockerfile.ubuntu.openjdk11 | 5 +- ga/latest/kernel/Dockerfile.ubuntu.openjdk17 | 5 +- 70 files changed, 2966 insertions(+), 18 deletions(-) create mode 100644 ga/23.0.0.7/README.md create mode 100644 ga/23.0.0.7/full/Dockerfile.ubi.ibmjava8 create mode 100644 ga/23.0.0.7/full/Dockerfile.ubi.openjdk11 create mode 100644 ga/23.0.0.7/full/Dockerfile.ubi.openjdk17 create mode 100644 ga/23.0.0.7/full/Dockerfile.ubi.openjdk8 create mode 100644 ga/23.0.0.7/full/Dockerfile.ubuntu.ibmjava8 create mode 100644 ga/23.0.0.7/full/Dockerfile.ubuntu.openjdk11 create mode 100644 ga/23.0.0.7/full/Dockerfile.ubuntu.openjdk17 create mode 100644 ga/23.0.0.7/full/README.md create mode 100644 ga/23.0.0.7/full/server.xml create mode 100644 ga/23.0.0.7/images.txt create mode 100644 ga/23.0.0.7/kernel/Dockerfile.ubi.ibmjava8 create mode 100644 ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk11 create mode 100644 ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk17 create mode 100644 ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk8 create mode 100644 ga/23.0.0.7/kernel/Dockerfile.ubuntu.ibmjava8 create mode 100644 ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk11 create mode 100644 ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk17 create mode 100644 ga/23.0.0.7/kernel/NOTICES create mode 100644 ga/23.0.0.7/kernel/README.md create mode 100644 ga/23.0.0.7/kernel/fixes/.gitkeep create mode 100755 ga/23.0.0.7/kernel/helpers/build/checkpoint.sh create mode 100644 ga/23.0.0.7/kernel/helpers/build/configuration_snippets/hazelcast-client.xml create mode 100644 ga/23.0.0.7/kernel/helpers/build/configuration_snippets/hazelcast-embedded.xml create mode 100644 ga/23.0.0.7/kernel/helpers/build/configuration_snippets/hazelcast-sessioncache-config.xml create mode 100644 ga/23.0.0.7/kernel/helpers/build/configuration_snippets/hazelcast-sessioncache.xml create mode 100644 ga/23.0.0.7/kernel/helpers/build/configuration_snippets/http-endpoint.xml create mode 100644 ga/23.0.0.7/kernel/helpers/build/configuration_snippets/http-ssl-endpoint.xml create mode 100644 ga/23.0.0.7/kernel/helpers/build/configuration_snippets/iiop-endpoint.xml create mode 100644 ga/23.0.0.7/kernel/helpers/build/configuration_snippets/iiop-ssl-endpoint.xml create mode 100644 ga/23.0.0.7/kernel/helpers/build/configuration_snippets/infinispan-client-sessioncache-config.xml create mode 100644 ga/23.0.0.7/kernel/helpers/build/configuration_snippets/infinispan-client-sessioncache.xml create mode 100644 ga/23.0.0.7/kernel/helpers/build/configuration_snippets/jms-endpoint.xml create mode 100644 ga/23.0.0.7/kernel/helpers/build/configuration_snippets/jms-ssl-endpoint.xml create mode 100644 ga/23.0.0.7/kernel/helpers/build/configuration_snippets/keystore.xml create mode 100644 ga/23.0.0.7/kernel/helpers/build/configuration_snippets/mp-health-check.xml create mode 100644 ga/23.0.0.7/kernel/helpers/build/configuration_snippets/mp-monitoring.xml create mode 100644 ga/23.0.0.7/kernel/helpers/build/configuration_snippets/oidc-config.xml create mode 100644 ga/23.0.0.7/kernel/helpers/build/configuration_snippets/oidc.xml create mode 100644 ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sessioncache-features.xml create mode 100644 ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sso-facebook.xml create mode 100644 ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sso-features.xml create mode 100644 ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sso-github.xml create mode 100644 ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sso-google.xml create mode 100644 ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sso-linkedin.xml create mode 100644 ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sso-oauth2.xml create mode 100644 ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sso-oidc.xml create mode 100644 ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sso-twitter.xml create mode 100644 ga/23.0.0.7/kernel/helpers/build/configuration_snippets/tls.xml create mode 100644 ga/23.0.0.7/kernel/helpers/build/configuration_snippets/trustDefault.xml create mode 100644 ga/23.0.0.7/kernel/helpers/build/configuration_snippets/truststore.xml create mode 100755 ga/23.0.0.7/kernel/helpers/build/configure.sh create mode 100755 ga/23.0.0.7/kernel/helpers/build/features.sh create mode 100755 ga/23.0.0.7/kernel/helpers/build/infinispan-client-setup.sh create mode 100755 ga/23.0.0.7/kernel/helpers/build/internal/features-installed.sh create mode 100755 ga/23.0.0.7/kernel/helpers/build/pidplus.sh create mode 100755 ga/23.0.0.7/kernel/helpers/build/populate_scc.sh create mode 100755 ga/23.0.0.7/kernel/helpers/runtime/docker-server.sh create mode 100755 ga/23.0.0.7/kernel/helpers/runtime/restore-server.sh create mode 100644 ga/23.0.0.7/oidcProvider/Dockerfile create mode 100644 ga/23.0.0.7/oidcProvider/Dockerfile.java11 create mode 100644 ga/23.0.0.7/oidcProvider/README.md create mode 100644 ga/23.0.0.7/oidcProvider/server.xml diff --git a/ga/23.0.0.7/README.md b/ga/23.0.0.7/README.md new file mode 100644 index 000000000..e0d4b8c1a --- /dev/null +++ b/ga/23.0.0.7/README.md @@ -0,0 +1,6 @@ +# WebSphere Application Server Developer Edition Liberty image + +Under this directory you can find build scripts for WebSphere Application Server Liberty container images: + +* [WebSphere Application Server Developer Edition Liberty, Kernel](kernel) +* [WebSphere Application Server Developer Edition Liberty, Full](full) diff --git a/ga/23.0.0.7/full/Dockerfile.ubi.ibmjava8 b/ga/23.0.0.7/full/Dockerfile.ubi.ibmjava8 new file mode 100644 index 000000000..2a2aef089 --- /dev/null +++ b/ga/23.0.0.7/full/Dockerfile.ubi.ibmjava8 @@ -0,0 +1,53 @@ +# (C) Copyright IBM Corporation 2023. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:kernel-java8-ibmjava-ubi +FROM $PARENT_IMAGE AS installBundle + +USER root + +ARG VERBOSE=false +ARG REPOSITORIES_PROPERTIES="" + +# If there is a local copy of the repository use that instead +COPY resources/ /tmp/ + +# Install the base bundle +RUN set -eux; \ + if [ ! -z "$REPOSITORIES_PROPERTIES" ]; then \ + mkdir /opt/ibm/wlp/etc/; \ + echo "$REPOSITORIES_PROPERTIES" > /opt/ibm/wlp/etc/repositories.properties; \ + installUtility install --acceptLicense baseBundle; \ + rm /opt/ibm/wlp/etc/repositories.properties; \ + elif [ -f /tmp/wlpRepo.zip ]; then \ + installUtility install --acceptLicense baseBundle --from=/tmp/wlpRepo.zip; \ + else \ + installUtility install --acceptLicense baseBundle; \ + fi; \ + rm -rf /output/workarea /output/logs; \ + find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw; + +ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:kernel-java8-ibmjava-ubi +FROM $PARENT_IMAGE +ARG VERBOSE=false + +# Copy the runtime +COPY --from=installBundle /opt/ibm/wlp /opt/ibm/wlp + +COPY --chown=1001:0 server.xml /config/ + +# Create a new SCC layer +RUN if [ "$OPENJ9_SCC" = "true" ]; then populate_scc.sh; fi \ + && rm -rf /output/messaging /output/resources/security /logs/* $WLP_OUTPUT_DIR/.classCache \ + && find /opt/ibm/wlp/output ! -path "*.classCache*" ! -perm -g=rwx -print0 | xargs -0 -r chmod g+rwx diff --git a/ga/23.0.0.7/full/Dockerfile.ubi.openjdk11 b/ga/23.0.0.7/full/Dockerfile.ubi.openjdk11 new file mode 100644 index 000000000..79f2900b0 --- /dev/null +++ b/ga/23.0.0.7/full/Dockerfile.ubi.openjdk11 @@ -0,0 +1,53 @@ +# (C) Copyright IBM Corporation 2023. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:kernel-java11-openj9-ubi +FROM $PARENT_IMAGE AS installBundle + +USER root + +ARG VERBOSE=false +ARG REPOSITORIES_PROPERTIES="" + +# If there is a local copy of the repository use that instead +COPY resources/ /tmp/ + +# Install the base bundle +RUN set -eux; \ + if [ ! -z "$REPOSITORIES_PROPERTIES" ]; then \ + mkdir /opt/ibm/wlp/etc/; \ + echo "$REPOSITORIES_PROPERTIES" > /opt/ibm/wlp/etc/repositories.properties; \ + installUtility install --acceptLicense baseBundle; \ + rm /opt/ibm/wlp/etc/repositories.properties; \ + elif [ -f /tmp/wlpRepo.zip ]; then \ + installUtility install --acceptLicense baseBundle --from=/tmp/wlpRepo.zip; \ + else \ + installUtility install --acceptLicense baseBundle; \ + fi; \ + rm -rf /output/workarea /output/logs; \ + find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw; + +ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:kernel-java11-openj9-ubi +FROM $PARENT_IMAGE +ARG VERBOSE=false + +# Copy the runtime +COPY --from=installBundle /opt/ibm/wlp /opt/ibm/wlp + +COPY --chown=1001:0 server.xml /config/ + +# Create a new SCC layer +RUN if [ "$OPENJ9_SCC" = "true" ]; then populate_scc.sh; fi \ + && rm -rf /output/messaging /output/resources/security /logs/* $WLP_OUTPUT_DIR/.classCache \ + && find /opt/ibm/wlp/output ! -perm -g=rwx -print0 | xargs -0 -r chmod g+rwx diff --git a/ga/23.0.0.7/full/Dockerfile.ubi.openjdk17 b/ga/23.0.0.7/full/Dockerfile.ubi.openjdk17 new file mode 100644 index 000000000..dc91e1978 --- /dev/null +++ b/ga/23.0.0.7/full/Dockerfile.ubi.openjdk17 @@ -0,0 +1,53 @@ +# (C) Copyright IBM Corporation 2023. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:kernel-java17-openj9-ubi +FROM $PARENT_IMAGE AS installBundle + +USER root + +ARG VERBOSE=false +ARG REPOSITORIES_PROPERTIES="" + +# If there is a local copy of the repository use that instead +COPY resources/ /tmp/ + +# Install the base bundle +RUN set -eux; \ + if [ ! -z "$REPOSITORIES_PROPERTIES" ]; then \ + mkdir /opt/ibm/wlp/etc/; \ + echo "$REPOSITORIES_PROPERTIES" > /opt/ibm/wlp/etc/repositories.properties; \ + installUtility install --acceptLicense baseBundle; \ + rm /opt/ibm/wlp/etc/repositories.properties; \ + elif [ -f /tmp/wlpRepo.zip ]; then \ + installUtility install --acceptLicense baseBundle --from=/tmp/wlpRepo.zip; \ + else \ + installUtility install --acceptLicense baseBundle; \ + fi; \ + rm -rf /output/workarea /output/logs; \ + find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw; + +ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:kernel-java17-openj9-ubi +FROM $PARENT_IMAGE +ARG VERBOSE=false + +# Copy the runtime +COPY --from=installBundle /opt/ibm/wlp /opt/ibm/wlp + +COPY --chown=1001:0 server.xml /config/ + +# Create a new SCC layer +RUN if [ "$OPENJ9_SCC" = "true" ]; then populate_scc.sh; fi \ + && rm -rf /output/messaging /output/resources/security /logs/* $WLP_OUTPUT_DIR/.classCache \ + && find /opt/ibm/wlp/output ! -perm -g=rwx -print0 | xargs -0 -r chmod g+rwx diff --git a/ga/23.0.0.7/full/Dockerfile.ubi.openjdk8 b/ga/23.0.0.7/full/Dockerfile.ubi.openjdk8 new file mode 100644 index 000000000..1d700de48 --- /dev/null +++ b/ga/23.0.0.7/full/Dockerfile.ubi.openjdk8 @@ -0,0 +1,53 @@ +# (C) Copyright IBM Corporation 2023. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:kernel-java8-openj9-ubi +FROM $PARENT_IMAGE AS installBundle + +USER root + +ARG VERBOSE=false +ARG REPOSITORIES_PROPERTIES="" + +# If there is a local copy of the repository use that instead +COPY resources/ /tmp/ + +# Install the base bundle +RUN set -eux; \ + if [ ! -z "$REPOSITORIES_PROPERTIES" ]; then \ + mkdir /opt/ibm/wlp/etc/; \ + echo "$REPOSITORIES_PROPERTIES" > /opt/ibm/wlp/etc/repositories.properties; \ + installUtility install --acceptLicense baseBundle; \ + rm /opt/ibm/wlp/etc/repositories.properties; \ + elif [ -f /tmp/wlpRepo.zip ]; then \ + installUtility install --acceptLicense baseBundle --from=/tmp/wlpRepo.zip; \ + else \ + installUtility install --acceptLicense baseBundle; \ + fi; \ + rm -rf /output/workarea /output/logs; \ + find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw; + +ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:kernel-java8-openj9-ubi +FROM $PARENT_IMAGE +ARG VERBOSE=false + +# Copy the runtime +COPY --from=installBundle /opt/ibm/wlp /opt/ibm/wlp + +COPY --chown=1001:0 server.xml /config/ + +# Create a new SCC layer +RUN if [ "$OPENJ9_SCC" = "true" ]; then populate_scc.sh; fi \ + && rm -rf /output/messaging /output/resources/security /logs/* $WLP_OUTPUT_DIR/.classCache \ + && find /opt/ibm/wlp/output ! -perm -g=rwx -print0 | xargs -0 -r chmod g+rwx diff --git a/ga/23.0.0.7/full/Dockerfile.ubuntu.ibmjava8 b/ga/23.0.0.7/full/Dockerfile.ubuntu.ibmjava8 new file mode 100644 index 000000000..395a6922a --- /dev/null +++ b/ga/23.0.0.7/full/Dockerfile.ubuntu.ibmjava8 @@ -0,0 +1,49 @@ +# (C) Copyright IBM Corporation 2023. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +FROM websphere-liberty:kernel AS installBundle +ARG VERBOSE=false +ARG REPOSITORIES_PROPERTIES="" + +# If there is a local copy of the repository use that instead +COPY resources/ /tmp/ + +# Install the base bundle +RUN set -eux; \ + if [ ! -z "$REPOSITORIES_PROPERTIES" ]; then \ + mkdir /opt/ibm/wlp/etc/; \ + echo "$REPOSITORIES_PROPERTIES" > /opt/ibm/wlp/etc/repositories.properties; \ + installUtility install --acceptLicense baseBundle; \ + rm /opt/ibm/wlp/etc/repositories.properties; \ + elif [ -f /tmp/wlpRepo.zip ]; then \ + installUtility install --acceptLicense baseBundle --from=/tmp/wlpRepo.zip; \ + else \ + installUtility install --acceptLicense baseBundle; \ + fi; \ + rm -rf /output/workarea /output/logs; \ + find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw; + +FROM websphere-liberty:kernel +ARG VERBOSE=false + +# Copy the runtime +COPY --from=installBundle /opt/ibm/wlp /opt/ibm/wlp + +COPY --chown=1001:0 server.xml /config/ + +# Create a new SCC layer +RUN if [ "$OPENJ9_SCC" = "true" ]; then populate_scc.sh; fi \ + && rm -rf /output/messaging /output/resources/security /logs/* $WLP_OUTPUT_DIR/.classCache \ + && find /opt/ibm/wlp/output ! -path "*.classCache*" ! -perm -g=rwx -print0 | xargs -0 -r chmod g+rwx + diff --git a/ga/23.0.0.7/full/Dockerfile.ubuntu.openjdk11 b/ga/23.0.0.7/full/Dockerfile.ubuntu.openjdk11 new file mode 100644 index 000000000..02fd841cd --- /dev/null +++ b/ga/23.0.0.7/full/Dockerfile.ubuntu.openjdk11 @@ -0,0 +1,51 @@ +# (C) Copyright IBM Corporation 2023. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +FROM websphere-liberty:kernel-java11-openj9 AS installBundle + +USER root + +ARG VERBOSE=false +ARG REPOSITORIES_PROPERTIES="" + +# If there is a local copy of the repository use that instead +COPY resources/ /tmp/ + +# Install the base bundle +RUN set -eux; \ + if [ ! -z "$REPOSITORIES_PROPERTIES" ]; then \ + mkdir /opt/ibm/wlp/etc/; \ + echo "$REPOSITORIES_PROPERTIES" > /opt/ibm/wlp/etc/repositories.properties; \ + installUtility install --acceptLicense baseBundle; \ + rm /opt/ibm/wlp/etc/repositories.properties; \ + elif [ -f /tmp/wlpRepo.zip ]; then \ + installUtility install --acceptLicense baseBundle --from=/tmp/wlpRepo.zip; \ + else \ + installUtility install --acceptLicense baseBundle; \ + fi; \ + rm -rf /output/workarea /output/logs; \ + find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw; + +FROM websphere-liberty:kernel-java11-openj9 +ARG VERBOSE=false + +# Copy the runtime +COPY --from=installBundle /opt/ibm/wlp /opt/ibm/wlp + +COPY --chown=1001:0 server.xml /config/ + +# Create a new SCC layer +RUN if [ "$OPENJ9_SCC" = "true" ]; then populate_scc.sh; fi \ + && rm -rf /output/messaging /output/resources/security /logs/* $WLP_OUTPUT_DIR/.classCache \ + && find /opt/ibm/wlp/output ! -perm -g=rwx -print0 | xargs -0 -r chmod g+rwx diff --git a/ga/23.0.0.7/full/Dockerfile.ubuntu.openjdk17 b/ga/23.0.0.7/full/Dockerfile.ubuntu.openjdk17 new file mode 100644 index 000000000..1241066c1 --- /dev/null +++ b/ga/23.0.0.7/full/Dockerfile.ubuntu.openjdk17 @@ -0,0 +1,51 @@ +# (C) Copyright IBM Corporation 2023. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +FROM websphere-liberty:kernel-java17-openj9 AS installBundle + +USER root + +ARG VERBOSE=false +ARG REPOSITORIES_PROPERTIES="" + +# If there is a local copy of the repository use that instead +COPY resources/ /tmp/ + +# Install the base bundle +RUN set -eux; \ + if [ ! -z "$REPOSITORIES_PROPERTIES" ]; then \ + mkdir /opt/ibm/wlp/etc/; \ + echo "$REPOSITORIES_PROPERTIES" > /opt/ibm/wlp/etc/repositories.properties; \ + installUtility install --acceptLicense baseBundle; \ + rm /opt/ibm/wlp/etc/repositories.properties; \ + elif [ -f /tmp/wlpRepo.zip ]; then \ + installUtility install --acceptLicense baseBundle --from=/tmp/wlpRepo.zip; \ + else \ + installUtility install --acceptLicense baseBundle; \ + fi; \ + rm -rf /output/workarea /output/logs; \ + find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw; + +FROM websphere-liberty:kernel-java17-openj9 +ARG VERBOSE=false + +# Copy the runtime +COPY --from=installBundle /opt/ibm/wlp /opt/ibm/wlp + +COPY --chown=1001:0 server.xml /config/ + +# Create a new SCC layer +RUN if [ "$OPENJ9_SCC" = "true" ]; then populate_scc.sh; fi \ + && rm -rf /output/messaging /output/resources/security /logs/* $WLP_OUTPUT_DIR/.classCache \ + && find /opt/ibm/wlp/output ! -perm -g=rwx -print0 | xargs -0 -r chmod g+rwx diff --git a/ga/23.0.0.7/full/README.md b/ga/23.0.0.7/full/README.md new file mode 100644 index 000000000..4292ed4c6 --- /dev/null +++ b/ga/23.0.0.7/full/README.md @@ -0,0 +1,7 @@ +# WebSphere Application Server Developer Edition Liberty image + +The [Dockerfile.ubuntu.ibmjava8](Dockerfile.ubuntu.ibmjava8) in this directory is used to build the `websphere-liberty:full` image on [Docker Hub](https://registry.hub.docker.com/_/websphere-liberty/). The image contains IBM WebSphere Liberty with an extensive set of features for convenience. + +# Usage + +Instructions for using the image can be found on [Docker Hub](https://registry.hub.docker.com/_/websphere-liberty/). It is possible to build the image yourself by cloning this repository, changing to the `ga//full` directory and then issuing the command to build container image. For example, with Docker execute `docker build .`. diff --git a/ga/23.0.0.7/full/server.xml b/ga/23.0.0.7/full/server.xml new file mode 100644 index 000000000..9d0b33f75 --- /dev/null +++ b/ga/23.0.0.7/full/server.xml @@ -0,0 +1,36 @@ + + + + + + javaee-8.0 + microProfile-3.0 + + + + + + + + + + + + + + + + + + + diff --git a/ga/23.0.0.7/images.txt b/ga/23.0.0.7/images.txt new file mode 100644 index 000000000..fd926b33e --- /dev/null +++ b/ga/23.0.0.7/images.txt @@ -0,0 +1,18 @@ +websphere-liberty:23.0.0.7-kernel ../ga/23.0.0.7/kernel ../ga/23.0.0.7/kernel/Dockerfile.ubuntu.ibmjava8 +websphere-liberty:23.0.0.7-kernel-java11-openj9 ../ga/23.0.0.7/kernel ../ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk11 +websphere-liberty:23.0.0.7-kernel-java17-openj9 ../ga/23.0.0.7/kernel ../ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk17 +websphere-liberty:23.0.0.7-kernel-java8-ibmjava-ubi ../ga/23.0.0.7/kernel ../ga/23.0.0.7/kernel/Dockerfile.ubi.ibmjava8 +websphere-liberty:23.0.0.7-kernel-java8-openj9-ubi ../ga/23.0.0.7/kernel ../ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk8 +websphere-liberty:23.0.0.7-kernel-java11-openj9-ubi ../ga/23.0.0.7/kernel ../ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk11 +websphere-liberty:23.0.0.7-kernel-java17-openj9-ubi ../ga/23.0.0.7/kernel ../ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk17 +websphere-liberty:23.0.0.7-full ../ga/23.0.0.7/full ../ga/23.0.0.7/full/Dockerfile.ubuntu.ibmjava8 +websphere-liberty:23.0.0.7-full-java11-openj9 ../ga/23.0.0.7/full ../ga/23.0.0.7/full/Dockerfile.ubuntu.openjdk11 +websphere-liberty:23.0.0.7-full-java17-openj9 ../ga/23.0.0.7/full ../ga/23.0.0.7/full/Dockerfile.ubuntu.openjdk17 +websphere-liberty:23.0.0.7-full-java8-ibmjava-ubi ../ga/23.0.0.7/full ../ga/23.0.0.7/full/Dockerfile.ubi.ibmjava8 +websphere-liberty:23.0.0.7-full-java8-openj9-ubi ../ga/23.0.0.7/full ../ga/23.0.0.7/full/Dockerfile.ubi.openjdk8 +websphere-liberty:23.0.0.7-full-java11-openj9-ubi ../ga/23.0.0.7/full ../ga/23.0.0.7/full/Dockerfile.ubi.openjdk11 +websphere-liberty:23.0.0.7-full-java17-openj9-ubi ../ga/23.0.0.7/full ../ga/23.0.0.7/full/Dockerfile.ubi.openjdk17 +websphere-liberty:beta ../beta +websphere-liberty:test-stock-quote test-stock-quote +websphere-liberty:test-stock-trader test-stock-trader +websphere-liberty:test-pet-clinic test-pet-clinic diff --git a/ga/23.0.0.7/kernel/Dockerfile.ubi.ibmjava8 b/ga/23.0.0.7/kernel/Dockerfile.ubi.ibmjava8 new file mode 100644 index 000000000..9d5ac1c1e --- /dev/null +++ b/ga/23.0.0.7/kernel/Dockerfile.ubi.ibmjava8 @@ -0,0 +1,175 @@ +# (C) Copyright IBM Corporation 2023. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +FROM ibmjava:8-ubi AS getRuntime + +USER root + +ARG VERBOSE=false + +# Install WebSphere Liberty +ARG LIBERTY_VERSION=23.0.0.7 +ARG LIBERTY_URL +ARG DOWNLOAD_OPTIONS="" + +# If there is a local copy of the image use that instead +COPY resources/ /tmp/ + +RUN yum -y install unzip wget openssl \ + && yum clean all \ + && mkdir -p /licenses \ + && useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ + && LIBERTY_URL=${LIBERTY_URL:-$(wget -q -O - https://public.dhe.ibm.com/ibmdl/export/pub/software/websphere/wasdev/downloads/wlp/index.yml | grep -E "^\s*kernel:.*${LIBERTY_VERSION}\.zip" | sed -n 's/\s*kernel:\s//p' | tr -d '\r' )} \ + && if [ ! -f /tmp/wlp.zip ]; then wget $DOWNLOAD_OPTIONS $LIBERTY_URL -U UA-IBM-WebSphere-Liberty-Docker -O /tmp/wlp.zip; fi \ + && chmod -R g+x /usr/bin \ + && unzip -q /tmp/wlp.zip -d /opt/ibm \ + && chown -R 1001:0 /opt/ibm/wlp \ + && chmod -R g+rw /opt/ibm/wlp \ + && cp -a /opt/ibm/wlp/lafiles/. /licenses/ + +FROM ibmjava:8-ubi + +USER root + +ARG VERBOSE=false +ARG OPENJ9_SCC=true + +ARG LIBERTY_VERSION=23.0.0.7 +ARG LIBERTY_BUILD_LABEL=cl230720230710-1201 + +LABEL org.opencontainers.image.authors="Leo Christy Jesuraj, Thomas Watson, Wendy Raschke, Michal Broz" \ + org.opencontainers.image.vendor="IBM" \ + org.opencontainers.image.url="https://github.com/WASdev/ci.docker" \ + org.opencontainers.image.documentation="https://www.ibm.com/support/knowledgecenter/SSAW57_liberty/com.ibm.websphere.wlp.nd.multiplatform.doc/ae/cwlp_about.html" \ + org.opencontainers.image.version="$LIBERTY_VERSION" \ + org.opencontainers.image.revision="$LIBERTY_BUILD_LABEL" \ + org.opencontainers.image.description="This image contains the WebSphere Liberty runtime with IBM's Java and Red Hat's UBI 8 as the base OS. For more information on this image please see https://ibm.biz/wl-app-image-template" \ + org.opencontainers.image.title="IBM WebSphere Liberty" \ + vendor="IBM" \ + name="IBM WebSphere Liberty" \ + version="$LIBERTY_VERSION" \ + summary="Image for WebSphere Liberty with IBM's Java and Red Hat's UBI 8" \ + description="This image contains the WebSphere Liberty runtime with IBM's Java and Red Hat's UBI 8 as the base OS. For more information on this image please see https://ibm.biz/wl-app-image-template" + +ENV PATH=$PATH:/opt/ibm/wlp/bin:/opt/ibm/helpers/build + +# Add labels for consumption by IBM Product Insights +LABEL "ProductID"="fbf6a96d49214c0abc6a3bc5da6e48cd" \ + "ProductName"="WebSphere Application Server Liberty" \ + "ProductVersion"="$LIBERTY_VERSION" \ + "BuildLabel"="$LIBERTY_BUILD_LABEL" + +# Install dumb-init +RUN set -eux; \ + ARCH="$(uname -m)"; \ + case "${ARCH}" in \ + aarch64|arm64) \ + DUMB_INIT_URL='https://github.com/Yelp/dumb-init/releases/download/v1.2.5/dumb-init_1.2.5_aarch64'; \ + DUMB_INIT_SHA256=b7d648f97154a99c539b63c55979cd29f005f88430fb383007fe3458340b795e; \ + ;; \ + amd64|x86_64) \ + DUMB_INIT_URL='https://github.com/Yelp/dumb-init/releases/download/v1.2.5/dumb-init_1.2.5_x86_64'; \ + DUMB_INIT_SHA256=e874b55f3279ca41415d290c512a7ba9d08f98041b28ae7c2acb19a545f1c4df; \ + ;; \ + ppc64el|ppc64le) \ + DUMB_INIT_URL='https://github.com/Yelp/dumb-init/releases/download/v1.2.5/dumb-init_1.2.5_ppc64le'; \ + DUMB_INIT_SHA256=3d15e80e29f0f4fa1fc686b00613a2220bc37e83a35283d4b4cca1fbd0a5609f; \ + ;; \ + s390x) \ + DUMB_INIT_URL='https://github.com/Yelp/dumb-init/releases/download/v1.2.5/dumb-init_1.2.5_s390x'; \ + DUMB_INIT_SHA256=47e4601b152fc6dcb1891e66c30ecc62a2939fd7ffd1515a7c30f281cfec53b7; \ + ;;\ + *) \ + echo "Unsupported arch: ${ARCH}"; \ + exit 1; \ + ;; \ + esac; \ + curl -LfsSo /usr/bin/dumb-init ${DUMB_INIT_URL}; \ + echo "${DUMB_INIT_SHA256} */usr/bin/dumb-init" | sha256sum -c -; \ + chmod +x /usr/bin/dumb-init; + +# Add default user 1001 and create wlp with right user/permissions before copying +RUN adduser -u 1001 -r -g root -s /usr/sbin/nologin default \ + && mkdir -p /opt/ibm/wlp \ + && chown -R 1001:0 /opt/ibm/wlp \ + && chmod -R g+rw /opt/ibm/wlp + +# Copy the runtime and licenses +COPY --from=getRuntime --chown=1001:0 /opt/ibm/wlp /opt/ibm/wlp +COPY --from=getRuntime /licenses /licenses + +RUN yum -y install openssl \ + && yum clean all +# Set Path Shortcuts +ENV LOG_DIR=/logs \ + WLP_OUTPUT_DIR=/opt/ibm/wlp/output \ + OPENJ9_SCC=$OPENJ9_SCC + +# Configure WebSphere Liberty +RUN /opt/ibm/wlp/bin/server create \ + && rm -rf $WLP_OUTPUT_DIR/.classCache /output/workarea \ + && rm -rf /opt/ibm/wlp/usr/servers/defaultServer/server.env + +COPY NOTICES /opt/ibm/NOTICES +COPY helpers/ /opt/ibm/helpers/ +COPY fixes/ /opt/ibm/fixes/ + +# Create symlinks && set permissions for non-root user +RUN mkdir /logs \ + && mkdir /etc/wlp \ + && mkdir -p /opt/ibm/wlp/usr/shared/resources/lib.index.cache \ + && mkdir -p /home/default \ + && mkdir /output \ + && chmod -t /output \ + && rm -rf /output \ + && ln -s $WLP_OUTPUT_DIR/defaultServer /output \ + && ln -s /opt/ibm/wlp/usr/servers/defaultServer /config \ + && ln -s /opt/ibm /liberty \ + && ln -s /opt/ibm/fixes /fixes \ + && ln -s /opt/ibm/wlp/usr/shared/resources/lib.index.cache /lib.index.cache \ + && mkdir -p /config/configDropins/defaults \ + && mkdir -p /config/configDropins/overrides \ + && chown -R 1001:0 /config \ + && chmod -R g+rw /config \ + && chown -R 1001:0 /opt/ibm/helpers \ + && chmod -R g+rwx /opt/ibm/helpers \ + && chown -R 1001:0 /opt/ibm/fixes \ + && chmod -R g+rwx /opt/ibm/fixes \ + && chown -R 1001:0 /opt/ibm/wlp/usr \ + && chmod -R g+rw /opt/ibm/wlp/usr \ + && chown -R 1001:0 /opt/ibm/wlp/output \ + && chmod -R g+rw /opt/ibm/wlp/output \ + && chown -R 1001:0 /logs \ + && chmod -R g+rw /logs \ + && chown -R 1001:0 /etc/wlp \ + && chmod -R g+rw /etc/wlp \ + && chown -R 1001:0 /home/default \ + && chmod -R g+rw /home/default + +# Create a new SCC layer +RUN if [ "$OPENJ9_SCC" = "true" ]; then populate_scc.sh; fi \ + && rm -rf /output/messaging /output/resources/security /logs/* $WLP_OUTPUT_DIR/.classCache \ + && chown -R 1001:0 /opt/ibm/wlp/output \ + && chmod -R g+rwx /opt/ibm/wlp/output + +# These settings are needed so that we can run as a different user than 1001 after server warmup +ENV RANDFILE=/tmp/.rnd \ + IBM_JAVA_OPTIONS="-Xshareclasses:name=liberty,readonly,nonfatal,cacheDir=/output/.classCache/ -Dosgi.checkConfiguration=false ${IBM_JAVA_OPTIONS}" + +USER 1001 + +EXPOSE 9080 9443 + +ENTRYPOINT ["/opt/ibm/helpers/runtime/docker-server.sh"] +CMD ["/opt/ibm/wlp/bin/server", "run", "defaultServer"] diff --git a/ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk11 b/ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk11 new file mode 100644 index 000000000..cbd5df5ec --- /dev/null +++ b/ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk11 @@ -0,0 +1,175 @@ +# (C) Copyright IBM Corporation 2023. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +FROM icr.io/appcafe/ibm-semeru-runtimes:open-11-jdk-ubi AS getRuntime + +USER root + +ARG VERBOSE=false + +# Install WebSphere Liberty +ARG LIBERTY_VERSION=23.0.0.7 +ARG LIBERTY_URL +ARG DOWNLOAD_OPTIONS="" + +# If there is a local copy of the image use that instead +COPY resources/ /tmp/ + +RUN yum -y install shadow-utils unzip wget findutils openssl \ + && yum clean all \ + && mkdir -p /licenses \ + && useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ + && LIBERTY_URL=${LIBERTY_URL:-$(wget -q -O - https://public.dhe.ibm.com/ibmdl/export/pub/software/websphere/wasdev/downloads/wlp/index.yml | grep -E "^\s*kernel:.*${LIBERTY_VERSION}\.zip" | sed -n 's/\s*kernel:\s//p' | tr -d '\r' )} \ + && if [ ! -f /tmp/wlp.zip ]; then wget $DOWNLOAD_OPTIONS $LIBERTY_URL -U UA-IBM-WebSphere-Liberty-Docker -O /tmp/wlp.zip; fi \ + && chmod -R g+x /usr/bin \ + && unzip -q /tmp/wlp.zip -d /opt/ibm \ + && chown -R 1001:0 /opt/ibm/wlp \ + && chmod -R g+rw /opt/ibm/wlp \ + && cp -a /opt/ibm/wlp/lafiles/. /licenses/ + +FROM icr.io/appcafe/ibm-semeru-runtimes:open-11-jdk-ubi + +USER root + +ARG VERBOSE=false +ARG OPENJ9_SCC=true + +ARG LIBERTY_VERSION=23.0.0.7 +ARG LIBERTY_BUILD_LABEL=cl230720230710-1201 + +LABEL org.opencontainers.image.authors="Leo Christy Jesuraj, Thomas Watson, Wendy Raschke, Michal Broz" \ + org.opencontainers.image.vendor="IBM" \ + org.opencontainers.image.url="https://github.com/WASdev/ci.docker" \ + org.opencontainers.image.documentation="https://www.ibm.com/support/knowledgecenter/SSAW57_liberty/com.ibm.websphere.wlp.nd.multiplatform.doc/ae/cwlp_about.html" \ + org.opencontainers.image.version="$LIBERTY_VERSION" \ + org.opencontainers.image.revision="$LIBERTY_BUILD_LABEL" \ + org.opencontainers.image.description="This image contains the WebSphere Liberty runtime with IBM Semeru Runtime Open Edition OpenJDK with OpenJ9 and Red Hat's UBI 8 as the base OS. For more information on this image please see https://ibm.biz/wl-app-image-template" \ + org.opencontainers.image.title="IBM WebSphere Liberty" \ + vendor="IBM" \ + name="IBM WebSphere Liberty" \ + version="$LIBERTY_VERSION" \ + summary="Image for WebSphere Liberty with IBM Semeru Runtime Open Edition OpenJDK with OpenJ9 and Red Hat's UBI 8" \ + description="This image contains the WebSphere Liberty runtime with IBM Semeru Runtime Open Edition OpenJDK with OpenJ9 and Red Hat's UBI 8 as the base OS. For more information on this image please see https://ibm.biz/wl-app-image-template" + +ENV PATH=$PATH:/opt/ibm/wlp/bin:/opt/ibm/helpers/build + +# Add labels for consumption by IBM Product Insights +LABEL "ProductID"="fbf6a96d49214c0abc6a3bc5da6e48cd" \ + "ProductName"="WebSphere Application Server Liberty" \ + "ProductVersion"="$LIBERTY_VERSION" \ + "BuildLabel"="$LIBERTY_BUILD_LABEL" + +# Install dumb-init +RUN set -eux; \ + ARCH="$(uname -m)"; \ + case "${ARCH}" in \ + aarch64|arm64) \ + DUMB_INIT_URL='https://github.com/Yelp/dumb-init/releases/download/v1.2.5/dumb-init_1.2.5_aarch64'; \ + DUMB_INIT_SHA256=b7d648f97154a99c539b63c55979cd29f005f88430fb383007fe3458340b795e; \ + ;; \ + amd64|x86_64) \ + DUMB_INIT_URL='https://github.com/Yelp/dumb-init/releases/download/v1.2.5/dumb-init_1.2.5_x86_64'; \ + DUMB_INIT_SHA256=e874b55f3279ca41415d290c512a7ba9d08f98041b28ae7c2acb19a545f1c4df; \ + ;; \ + ppc64el|ppc64le) \ + DUMB_INIT_URL='https://github.com/Yelp/dumb-init/releases/download/v1.2.5/dumb-init_1.2.5_ppc64le'; \ + DUMB_INIT_SHA256=3d15e80e29f0f4fa1fc686b00613a2220bc37e83a35283d4b4cca1fbd0a5609f; \ + ;; \ + s390x) \ + DUMB_INIT_URL='https://github.com/Yelp/dumb-init/releases/download/v1.2.5/dumb-init_1.2.5_s390x'; \ + DUMB_INIT_SHA256=47e4601b152fc6dcb1891e66c30ecc62a2939fd7ffd1515a7c30f281cfec53b7; \ + ;;\ + *) \ + echo "Unsupported arch: ${ARCH}"; \ + exit 1; \ + ;; \ + esac; \ + curl -LfsSo /usr/bin/dumb-init ${DUMB_INIT_URL}; \ + echo "${DUMB_INIT_SHA256} */usr/bin/dumb-init" | sha256sum -c -; \ + chmod +x /usr/bin/dumb-init; + +# Add default user 1001 and create wlp with right user/permissions before copying +RUN adduser -u 1001 -r -g root -s /usr/sbin/nologin default \ + && mkdir -p /opt/ibm/wlp \ + && chown -R 1001:0 /opt/ibm/wlp \ + && chmod -R g+rw /opt/ibm/wlp + +# Copy the runtime and licenses +COPY --from=getRuntime --chown=1001:0 /opt/ibm/wlp /opt/ibm/wlp +COPY --from=getRuntime /licenses /licenses + +RUN yum -y install openssl \ + && yum clean all +# Set Path Shortcuts +ENV LOG_DIR=/logs \ + WLP_OUTPUT_DIR=/opt/ibm/wlp/output \ + OPENJ9_SCC=$OPENJ9_SCC + +# Configure WebSphere Liberty +RUN /opt/ibm/wlp/bin/server create \ + && rm -rf $WLP_OUTPUT_DIR/.classCache /output/workarea \ + && rm -rf /opt/ibm/wlp/usr/servers/defaultServer/server.env + +COPY NOTICES /opt/ibm/NOTICES +COPY helpers/ /opt/ibm/helpers/ +COPY fixes/ /opt/ibm/fixes/ + +# Create symlinks && set permissions for non-root user +RUN mkdir /logs \ + && mkdir /etc/wlp \ + && mkdir -p /opt/ibm/wlp/usr/shared/resources/lib.index.cache \ + && mkdir -p /home/default \ + && mkdir /output \ + && chmod -t /output \ + && rm -rf /output \ + && ln -s $WLP_OUTPUT_DIR/defaultServer /output \ + && ln -s /opt/ibm/wlp/usr/servers/defaultServer /config \ + && ln -s /opt/ibm /liberty \ + && ln -s /opt/ibm/fixes /fixes \ + && ln -s /opt/ibm/wlp/usr/shared/resources/lib.index.cache /lib.index.cache \ + && mkdir -p /config/configDropins/defaults \ + && mkdir -p /config/configDropins/overrides \ + && chown -R 1001:0 /config \ + && chmod -R g+rw /config \ + && chown -R 1001:0 /opt/ibm/helpers \ + && chmod -R g+rwx /opt/ibm/helpers \ + && chown -R 1001:0 /opt/ibm/fixes \ + && chmod -R g+rwx /opt/ibm/fixes \ + && chown -R 1001:0 /opt/ibm/wlp/usr \ + && chmod -R g+rw /opt/ibm/wlp/usr \ + && chown -R 1001:0 /opt/ibm/wlp/output \ + && chmod -R g+rw /opt/ibm/wlp/output \ + && chown -R 1001:0 /logs \ + && chmod -R g+rw /logs \ + && chown -R 1001:0 /etc/wlp \ + && chmod -R g+rw /etc/wlp \ + && chown -R 1001:0 /home/default \ + && chmod -R g+rw /home/default + +# Create a new SCC layer +RUN if [ "$OPENJ9_SCC" = "true" ]; then populate_scc.sh; fi \ + && rm -rf /output/messaging /output/resources/security /logs/* $WLP_OUTPUT_DIR/.classCache \ + && chown -R 1001:0 /opt/ibm/wlp/output \ + && chmod -R g+rwx /opt/ibm/wlp/output + +# These settings are needed so that we can run as a different user than 1001 after server warmup +ENV RANDFILE=/tmp/.rnd \ + OPENJ9_JAVA_OPTIONS="-XX:+IgnoreUnrecognizedVMOptions -XX:+IdleTuningGcOnIdle -Xshareclasses:name=openj9_system_scc,cacheDir=/opt/java/.scc,readonly,nonFatal -Dosgi.checkConfiguration=false" + +USER 1001 + +EXPOSE 9080 9443 + +ENTRYPOINT ["/opt/ibm/helpers/runtime/docker-server.sh"] +CMD ["/opt/ibm/wlp/bin/server", "run", "defaultServer"] diff --git a/ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk17 b/ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk17 new file mode 100644 index 000000000..bdf26a8a1 --- /dev/null +++ b/ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk17 @@ -0,0 +1,175 @@ +# (C) Copyright IBM Corporation 2023. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +FROM icr.io/appcafe/ibm-semeru-runtimes:open-17-jdk-ubi AS getRuntime + +USER root + +ARG VERBOSE=false + +# Install WebSphere Liberty +ARG LIBERTY_VERSION=23.0.0.7 +ARG LIBERTY_URL +ARG DOWNLOAD_OPTIONS="" + +# If there is a local copy of the image use that instead +COPY resources/ /tmp/ + +RUN yum -y install shadow-utils unzip wget findutils openssl \ + && yum clean all \ + && mkdir -p /licenses \ + && useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ + && LIBERTY_URL=${LIBERTY_URL:-$(wget -q -O - https://public.dhe.ibm.com/ibmdl/export/pub/software/websphere/wasdev/downloads/wlp/index.yml | grep -E "^\s*kernel:.*${LIBERTY_VERSION}\.zip" | sed -n 's/\s*kernel:\s//p' | tr -d '\r' )} \ + && if [ ! -f /tmp/wlp.zip ]; then wget $DOWNLOAD_OPTIONS $LIBERTY_URL -U UA-IBM-WebSphere-Liberty-Docker -O /tmp/wlp.zip; fi \ + && chmod -R g+x /usr/bin \ + && unzip -q /tmp/wlp.zip -d /opt/ibm \ + && chown -R 1001:0 /opt/ibm/wlp \ + && chmod -R g+rw /opt/ibm/wlp \ + && cp -a /opt/ibm/wlp/lafiles/. /licenses/ + +FROM icr.io/appcafe/ibm-semeru-runtimes:open-17-jdk-ubi + +USER root + +ARG VERBOSE=false +ARG OPENJ9_SCC=true + +ARG LIBERTY_VERSION=23.0.0.7 +ARG LIBERTY_BUILD_LABEL=cl230720230710-1201 + +LABEL org.opencontainers.image.authors="Leo Christy Jesuraj, Thomas Watson, Wendy Raschke, Michal Broz" \ + org.opencontainers.image.vendor="IBM" \ + org.opencontainers.image.url="https://github.com/WASdev/ci.docker" \ + org.opencontainers.image.documentation="https://www.ibm.com/support/knowledgecenter/SSAW57_liberty/com.ibm.websphere.wlp.nd.multiplatform.doc/ae/cwlp_about.html" \ + org.opencontainers.image.version="$LIBERTY_VERSION" \ + org.opencontainers.image.revision="$LIBERTY_BUILD_LABEL" \ + org.opencontainers.image.description="This image contains the WebSphere Liberty runtime with IBM Semeru Runtime Open Edition OpenJDK with OpenJ9 and Red Hat's UBI 8 as the base OS. For more information on this image please see https://ibm.biz/wl-app-image-template" \ + org.opencontainers.image.title="IBM WebSphere Liberty" \ + vendor="IBM" \ + name="IBM WebSphere Liberty" \ + version="$LIBERTY_VERSION" \ + summary="Image for WebSphere Liberty with IBM Semeru Runtime Open Edition OpenJDK with OpenJ9 and Red Hat's UBI 8" \ + description="This image contains the WebSphere Liberty runtime with IBM Semeru Runtime Open Edition OpenJDK with OpenJ9 and Red Hat's UBI 8 as the base OS. For more information on this image please see https://ibm.biz/wl-app-image-template" + +ENV PATH=$PATH:/opt/ibm/wlp/bin:/opt/ibm/helpers/build + +# Add labels for consumption by IBM Product Insights +LABEL "ProductID"="fbf6a96d49214c0abc6a3bc5da6e48cd" \ + "ProductName"="WebSphere Application Server Liberty" \ + "ProductVersion"="$LIBERTY_VERSION" \ + "BuildLabel"="$LIBERTY_BUILD_LABEL" + +# Install dumb-init +RUN set -eux; \ + ARCH="$(uname -m)"; \ + case "${ARCH}" in \ + aarch64|arm64) \ + DUMB_INIT_URL='https://github.com/Yelp/dumb-init/releases/download/v1.2.5/dumb-init_1.2.5_aarch64'; \ + DUMB_INIT_SHA256=b7d648f97154a99c539b63c55979cd29f005f88430fb383007fe3458340b795e; \ + ;; \ + amd64|x86_64) \ + DUMB_INIT_URL='https://github.com/Yelp/dumb-init/releases/download/v1.2.5/dumb-init_1.2.5_x86_64'; \ + DUMB_INIT_SHA256=e874b55f3279ca41415d290c512a7ba9d08f98041b28ae7c2acb19a545f1c4df; \ + ;; \ + ppc64el|ppc64le) \ + DUMB_INIT_URL='https://github.com/Yelp/dumb-init/releases/download/v1.2.5/dumb-init_1.2.5_ppc64le'; \ + DUMB_INIT_SHA256=3d15e80e29f0f4fa1fc686b00613a2220bc37e83a35283d4b4cca1fbd0a5609f; \ + ;; \ + s390x) \ + DUMB_INIT_URL='https://github.com/Yelp/dumb-init/releases/download/v1.2.5/dumb-init_1.2.5_s390x'; \ + DUMB_INIT_SHA256=47e4601b152fc6dcb1891e66c30ecc62a2939fd7ffd1515a7c30f281cfec53b7; \ + ;;\ + *) \ + echo "Unsupported arch: ${ARCH}"; \ + exit 1; \ + ;; \ + esac; \ + curl -LfsSo /usr/bin/dumb-init ${DUMB_INIT_URL}; \ + echo "${DUMB_INIT_SHA256} */usr/bin/dumb-init" | sha256sum -c -; \ + chmod +x /usr/bin/dumb-init; + +# Add default user 1001 and create wlp with right user/permissions before copying +RUN adduser -u 1001 -r -g root -s /usr/sbin/nologin default \ + && mkdir -p /opt/ibm/wlp \ + && chown -R 1001:0 /opt/ibm/wlp \ + && chmod -R g+rw /opt/ibm/wlp + +# Copy the runtime and licenses +COPY --from=getRuntime --chown=1001:0 /opt/ibm/wlp /opt/ibm/wlp +COPY --from=getRuntime /licenses /licenses + +RUN yum -y install openssl \ + && yum clean all +# Set Path Shortcuts +ENV LOG_DIR=/logs \ + WLP_OUTPUT_DIR=/opt/ibm/wlp/output \ + OPENJ9_SCC=$OPENJ9_SCC + +# Configure WebSphere Liberty +RUN /opt/ibm/wlp/bin/server create \ + && rm -rf $WLP_OUTPUT_DIR/.classCache /output/workarea \ + && rm -rf /opt/ibm/wlp/usr/servers/defaultServer/server.env + +COPY NOTICES /opt/ibm/NOTICES +COPY helpers/ /opt/ibm/helpers/ +COPY fixes/ /opt/ibm/fixes/ + +# Create symlinks && set permissions for non-root user +RUN mkdir /logs \ + && mkdir /etc/wlp \ + && mkdir -p /opt/ibm/wlp/usr/shared/resources/lib.index.cache \ + && mkdir -p /home/default \ + && mkdir /output \ + && chmod -t /output \ + && rm -rf /output \ + && ln -s $WLP_OUTPUT_DIR/defaultServer /output \ + && ln -s /opt/ibm/wlp/usr/servers/defaultServer /config \ + && ln -s /opt/ibm /liberty \ + && ln -s /opt/ibm/fixes /fixes \ + && ln -s /opt/ibm/wlp/usr/shared/resources/lib.index.cache /lib.index.cache \ + && mkdir -p /config/configDropins/defaults \ + && mkdir -p /config/configDropins/overrides \ + && chown -R 1001:0 /config \ + && chmod -R g+rw /config \ + && chown -R 1001:0 /opt/ibm/helpers \ + && chmod -R g+rwx /opt/ibm/helpers \ + && chown -R 1001:0 /opt/ibm/fixes \ + && chmod -R g+rwx /opt/ibm/fixes \ + && chown -R 1001:0 /opt/ibm/wlp/usr \ + && chmod -R g+rw /opt/ibm/wlp/usr \ + && chown -R 1001:0 /opt/ibm/wlp/output \ + && chmod -R g+rw /opt/ibm/wlp/output \ + && chown -R 1001:0 /logs \ + && chmod -R g+rw /logs \ + && chown -R 1001:0 /etc/wlp \ + && chmod -R g+rw /etc/wlp \ + && chown -R 1001:0 /home/default \ + && chmod -R g+rw /home/default + +# Create a new SCC layer +RUN if [ "$OPENJ9_SCC" = "true" ]; then populate_scc.sh; fi \ + && rm -rf /output/messaging /output/resources/security /logs/* $WLP_OUTPUT_DIR/.classCache \ + && chown -R 1001:0 /opt/ibm/wlp/output \ + && chmod -R g+rwx /opt/ibm/wlp/output + +# These settings are needed so that we can run as a different user than 1001 after server warmup +ENV RANDFILE=/tmp/.rnd \ + OPENJ9_JAVA_OPTIONS="-XX:+IgnoreUnrecognizedVMOptions -XX:+IdleTuningGcOnIdle -Xshareclasses:name=openj9_system_scc,cacheDir=/opt/java/.scc,readonly,nonFatal -Dosgi.checkConfiguration=false" + +USER 1001 + +EXPOSE 9080 9443 + +ENTRYPOINT ["/opt/ibm/helpers/runtime/docker-server.sh"] +CMD ["/opt/ibm/wlp/bin/server", "run", "defaultServer"] diff --git a/ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk8 b/ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk8 new file mode 100644 index 000000000..2484c6586 --- /dev/null +++ b/ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk8 @@ -0,0 +1,175 @@ +# (C) Copyright IBM Corporation 2023. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +FROM icr.io/appcafe/ibm-semeru-runtimes:open-8-jdk-ubi AS getRuntime + +USER root + +ARG VERBOSE=false + +# Install WebSphere Liberty +ARG LIBERTY_VERSION=23.0.0.7 +ARG LIBERTY_URL +ARG DOWNLOAD_OPTIONS="" + +# If there is a local copy of the image use that instead +COPY resources/ /tmp/ + +RUN yum -y install shadow-utils unzip wget findutils openssl \ + && yum clean all \ + && mkdir -p /licenses \ + && useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ + && LIBERTY_URL=${LIBERTY_URL:-$(wget -q -O - https://public.dhe.ibm.com/ibmdl/export/pub/software/websphere/wasdev/downloads/wlp/index.yml | grep -E "^\s*kernel:.*${LIBERTY_VERSION}\.zip" | sed -n 's/\s*kernel:\s//p' | tr -d '\r' )} \ + && if [ ! -f /tmp/wlp.zip ]; then wget $DOWNLOAD_OPTIONS $LIBERTY_URL -U UA-IBM-WebSphere-Liberty-Docker -O /tmp/wlp.zip; fi \ + && chmod -R g+x /usr/bin \ + && unzip -q /tmp/wlp.zip -d /opt/ibm \ + && chown -R 1001:0 /opt/ibm/wlp \ + && chmod -R g+rw /opt/ibm/wlp \ + && cp -a /opt/ibm/wlp/lafiles/. /licenses/ + +FROM icr.io/appcafe/ibm-semeru-runtimes:open-8-jdk-ubi + +USER root + +ARG VERBOSE=false +ARG OPENJ9_SCC=true + +ARG LIBERTY_VERSION=23.0.0.7 +ARG LIBERTY_BUILD_LABEL=cl230720230710-1201 + +LABEL org.opencontainers.image.authors="Leo Christy Jesuraj, Thomas Watson, Wendy Raschke, Michal Broz" \ + org.opencontainers.image.vendor="IBM" \ + org.opencontainers.image.url="https://github.com/WASdev/ci.docker" \ + org.opencontainers.image.documentation="https://www.ibm.com/support/knowledgecenter/SSAW57_liberty/com.ibm.websphere.wlp.nd.multiplatform.doc/ae/cwlp_about.html" \ + org.opencontainers.image.version="$LIBERTY_VERSION" \ + org.opencontainers.image.revision="$LIBERTY_BUILD_LABEL" \ + org.opencontainers.image.description="This image contains the WebSphere Liberty runtime with IBM Semeru Runtime Open Edition OpenJDK with OpenJ9 and Red Hat's UBI 8 as the base OS. For more information on this image please see https://ibm.biz/wl-app-image-template" \ + org.opencontainers.image.title="IBM WebSphere Liberty" \ + vendor="IBM" \ + name="IBM WebSphere Liberty" \ + version="$LIBERTY_VERSION" \ + summary="Image for WebSphere Liberty with IBM Semeru Runtime Open Edition OpenJDK with OpenJ9 and Red Hat's UBI 8" \ + description="This image contains the WebSphere Liberty runtime with IBM Semeru Runtime Open Edition OpenJDK with OpenJ9 and Red Hat's UBI 8 as the base OS. For more information on this image please see https://ibm.biz/wl-app-image-template" + +ENV PATH=$PATH:/opt/ibm/wlp/bin:/opt/ibm/helpers/build + +# Add labels for consumption by IBM Product Insights +LABEL "ProductID"="fbf6a96d49214c0abc6a3bc5da6e48cd" \ + "ProductName"="WebSphere Application Server Liberty" \ + "ProductVersion"="$LIBERTY_VERSION" \ + "BuildLabel"="$LIBERTY_BUILD_LABEL" + +# Install dumb-init +RUN set -eux; \ + ARCH="$(uname -m)"; \ + case "${ARCH}" in \ + aarch64|arm64) \ + DUMB_INIT_URL='https://github.com/Yelp/dumb-init/releases/download/v1.2.5/dumb-init_1.2.5_aarch64'; \ + DUMB_INIT_SHA256=b7d648f97154a99c539b63c55979cd29f005f88430fb383007fe3458340b795e; \ + ;; \ + amd64|x86_64) \ + DUMB_INIT_URL='https://github.com/Yelp/dumb-init/releases/download/v1.2.5/dumb-init_1.2.5_x86_64'; \ + DUMB_INIT_SHA256=e874b55f3279ca41415d290c512a7ba9d08f98041b28ae7c2acb19a545f1c4df; \ + ;; \ + ppc64el|ppc64le) \ + DUMB_INIT_URL='https://github.com/Yelp/dumb-init/releases/download/v1.2.5/dumb-init_1.2.5_ppc64le'; \ + DUMB_INIT_SHA256=3d15e80e29f0f4fa1fc686b00613a2220bc37e83a35283d4b4cca1fbd0a5609f; \ + ;; \ + s390x) \ + DUMB_INIT_URL='https://github.com/Yelp/dumb-init/releases/download/v1.2.5/dumb-init_1.2.5_s390x'; \ + DUMB_INIT_SHA256=47e4601b152fc6dcb1891e66c30ecc62a2939fd7ffd1515a7c30f281cfec53b7; \ + ;;\ + *) \ + echo "Unsupported arch: ${ARCH}"; \ + exit 1; \ + ;; \ + esac; \ + curl -LfsSo /usr/bin/dumb-init ${DUMB_INIT_URL}; \ + echo "${DUMB_INIT_SHA256} */usr/bin/dumb-init" | sha256sum -c -; \ + chmod +x /usr/bin/dumb-init; + +# Add default user 1001 and create wlp with right user/permissions before copying +RUN adduser -u 1001 -r -g root -s /usr/sbin/nologin default \ + && mkdir -p /opt/ibm/wlp \ + && chown -R 1001:0 /opt/ibm/wlp \ + && chmod -R g+rw /opt/ibm/wlp + +# Copy the runtime and licenses +COPY --from=getRuntime --chown=1001:0 /opt/ibm/wlp /opt/ibm/wlp +COPY --from=getRuntime /licenses /licenses + +RUN yum -y install openssl \ + && yum clean all +# Set Path Shortcuts +ENV LOG_DIR=/logs \ + WLP_OUTPUT_DIR=/opt/ibm/wlp/output \ + OPENJ9_SCC=$OPENJ9_SCC + +# Configure WebSphere Liberty +RUN /opt/ibm/wlp/bin/server create \ + && rm -rf $WLP_OUTPUT_DIR/.classCache /output/workarea \ + && rm -rf /opt/ibm/wlp/usr/servers/defaultServer/server.env + +COPY NOTICES /opt/ibm/NOTICES +COPY helpers/ /opt/ibm/helpers/ +COPY fixes/ /opt/ibm/fixes/ + +# Create symlinks && set permissions for non-root user +RUN mkdir /logs \ + && mkdir /etc/wlp \ + && mkdir -p /opt/ibm/wlp/usr/shared/resources/lib.index.cache \ + && mkdir -p /home/default \ + && mkdir /output \ + && chmod -t /output \ + && rm -rf /output \ + && ln -s $WLP_OUTPUT_DIR/defaultServer /output \ + && ln -s /opt/ibm/wlp/usr/servers/defaultServer /config \ + && ln -s /opt/ibm /liberty \ + && ln -s /opt/ibm/fixes /fixes \ + && ln -s /opt/ibm/wlp/usr/shared/resources/lib.index.cache /lib.index.cache \ + && mkdir -p /config/configDropins/defaults \ + && mkdir -p /config/configDropins/overrides \ + && chown -R 1001:0 /config \ + && chmod -R g+rw /config \ + && chown -R 1001:0 /opt/ibm/helpers \ + && chmod -R g+rwx /opt/ibm/helpers \ + && chown -R 1001:0 /opt/ibm/fixes \ + && chmod -R g+rwx /opt/ibm/fixes \ + && chown -R 1001:0 /opt/ibm/wlp/usr \ + && chmod -R g+rw /opt/ibm/wlp/usr \ + && chown -R 1001:0 /opt/ibm/wlp/output \ + && chmod -R g+rw /opt/ibm/wlp/output \ + && chown -R 1001:0 /logs \ + && chmod -R g+rw /logs \ + && chown -R 1001:0 /etc/wlp \ + && chmod -R g+rw /etc/wlp \ + && chown -R 1001:0 /home/default \ + && chmod -R g+rw /home/default + +# Create a new SCC layer +RUN if [ "$OPENJ9_SCC" = "true" ]; then populate_scc.sh; fi \ + && rm -rf /output/messaging /output/resources/security /logs/* $WLP_OUTPUT_DIR/.classCache \ + && chown -R 1001:0 /opt/ibm/wlp/output \ + && chmod -R g+rwx /opt/ibm/wlp/output + +# These settings are needed so that we can run as a different user than 1001 after server warmup +ENV RANDFILE=/tmp/.rnd \ + OPENJ9_JAVA_OPTIONS="-XX:+IgnoreUnrecognizedVMOptions -XX:+IdleTuningGcOnIdle -Xshareclasses:name=openj9_system_scc,cacheDir=/opt/java/.scc,readonly,nonFatal -Dosgi.checkConfiguration=false" + +USER 1001 + +EXPOSE 9080 9443 + +ENTRYPOINT ["/opt/ibm/helpers/runtime/docker-server.sh"] +CMD ["/opt/ibm/wlp/bin/server", "run", "defaultServer"] diff --git a/ga/23.0.0.7/kernel/Dockerfile.ubuntu.ibmjava8 b/ga/23.0.0.7/kernel/Dockerfile.ubuntu.ibmjava8 new file mode 100644 index 000000000..796d40ac0 --- /dev/null +++ b/ga/23.0.0.7/kernel/Dockerfile.ubuntu.ibmjava8 @@ -0,0 +1,175 @@ +# (C) Copyright IBM Corporation 2023. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +FROM ibmjava:8-jre AS getRuntime + +USER root + +ARG VERBOSE=false + +# Install WebSphere Liberty +ARG LIBERTY_VERSION=23.0.0.7 +ARG LIBERTY_URL +ARG DOWNLOAD_OPTIONS="" + +# If there is a local copy of the image use that instead +COPY resources/ /tmp/ + +RUN apt-get update \ + && apt-get install -y --no-install-recommends unzip wget openssl \ + && rm -rf /var/lib/apt/lists/* \ + && mkdir -p /licenses/ \ + && useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ + && LIBERTY_URL=${LIBERTY_URL:-$(wget -q -O - https://public.dhe.ibm.com/ibmdl/export/pub/software/websphere/wasdev/downloads/wlp/index.yml | grep -E "^\s*kernel:.*${LIBERTY_VERSION}\.zip" | sed -n 's/\s*kernel:\s//p' | tr -d '\r' )} \ + && if [ ! -f /tmp/wlp.zip ]; then wget $DOWNLOAD_OPTIONS $LIBERTY_URL -U UA-IBM-WebSphere-Liberty-Docker -O /tmp/wlp.zip; fi \ + && unzip -q /tmp/wlp.zip -d /opt/ibm \ + && chown -R 1001:0 /opt/ibm/wlp \ + && chmod -R g+rw /opt/ibm/wlp \ + && cp -a /opt/ibm/wlp/lafiles/. /licenses/ + +FROM ibmjava:8-jre + +USER root + +ARG VERBOSE=false +ARG OPENJ9_SCC=true + +ARG LIBERTY_VERSION=23.0.0.7 +ARG LIBERTY_BUILD_LABEL=cl230720230710-1201 + +LABEL org.opencontainers.image.authors="Leo Christy Jesuraj, Thomas Watson, Wendy Raschke, Michal Broz" \ + org.opencontainers.image.vendor="IBM" \ + org.opencontainers.image.url="https://github.com/WASdev/ci.docker" \ + org.opencontainers.image.documentation="https://www.ibm.com/support/knowledgecenter/SSAW57_liberty/com.ibm.websphere.wlp.nd.multiplatform.doc/ae/cwlp_about.html" \ + org.opencontainers.image.version="$LIBERTY_VERSION" \ + org.opencontainers.image.revision="$LIBERTY_BUILD_LABEL" \ + org.opencontainers.image.description="This image contains the WebSphere Liberty runtime with IBM Semeru Runtime Open Edition OpenJDK with OpenJ9 and Ubuntu as the base OS. For more information on this image please see https://ibm.biz/wl-app-image-template" \ + org.opencontainers.image.title="IBM WebSphere Liberty" + +ENV PATH=$PATH:/opt/ibm/wlp/bin:/opt/ibm/helpers/build + +# Add labels for consumption by IBM Product Insights +LABEL "ProductID"="fbf6a96d49214c0abc6a3bc5da6e48cd" \ + "ProductName"="WebSphere Application Server Liberty" \ + "ProductVersion"="$LIBERTY_VERSION" \ + "BuildLabel"="$LIBERTY_BUILD_LABEL" + +# Install dumb-init +RUN set -eux; \ + apt-get update; \ + apt-get install -y curl; \ + ARCH="$(dpkg --print-architecture)"; \ + case "${ARCH}" in \ + aarch64|arm64) \ + DUMB_INIT_URL='https://github.com/Yelp/dumb-init/releases/download/v1.2.5/dumb-init_1.2.5_aarch64'; \ + DUMB_INIT_SHA256=b7d648f97154a99c539b63c55979cd29f005f88430fb383007fe3458340b795e; \ + ;; \ + amd64|x86_64) \ + DUMB_INIT_URL='https://github.com/Yelp/dumb-init/releases/download/v1.2.5/dumb-init_1.2.5_x86_64'; \ + DUMB_INIT_SHA256=e874b55f3279ca41415d290c512a7ba9d08f98041b28ae7c2acb19a545f1c4df; \ + ;; \ + ppc64el|ppc64le) \ + DUMB_INIT_URL='https://github.com/Yelp/dumb-init/releases/download/v1.2.5/dumb-init_1.2.5_ppc64le'; \ + DUMB_INIT_SHA256=3d15e80e29f0f4fa1fc686b00613a2220bc37e83a35283d4b4cca1fbd0a5609f; \ + ;; \ + s390x) \ + DUMB_INIT_URL='https://github.com/Yelp/dumb-init/releases/download/v1.2.5/dumb-init_1.2.5_s390x'; \ + DUMB_INIT_SHA256=47e4601b152fc6dcb1891e66c30ecc62a2939fd7ffd1515a7c30f281cfec53b7; \ + ;;\ + *) \ + echo "Unsupported arch: ${ARCH}"; \ + exit 1; \ + ;; \ + esac; \ + curl -LfsSo /usr/bin/dumb-init ${DUMB_INIT_URL}; \ + echo "${DUMB_INIT_SHA256} */usr/bin/dumb-init" | sha256sum -c -; \ + chmod +x /usr/bin/dumb-init; \ + apt-get purge --auto-remove -y wget; \ + rm -rf /var/lib/apt/lists/*; + +# Add default user 1001 and create wlp with right user/permissions before copying +RUN useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ + && mkdir -p /opt/ibm/wlp \ + && chown -R 1001:0 /opt/ibm/wlp \ + && chmod -R g+rw /opt/ibm/wlp + +# Copy the runtime and licenses +COPY --from=getRuntime --chown=1001:0 /opt/ibm/wlp /opt/ibm/wlp +COPY --from=getRuntime /licenses /licenses + +RUN apt-get install -y --no-install-recommends openssl \ + && rm -rf /var/lib/apt/lists/* + +# Set Path Shortcuts +ENV LOG_DIR=/logs \ + WLP_OUTPUT_DIR=/opt/ibm/wlp/output \ + OPENJ9_SCC=$OPENJ9_SCC + +# Configure WebSphere Liberty +RUN /opt/ibm/wlp/bin/server create \ + && rm -rf $WLP_OUTPUT_DIR/.classCache /output/workarea \ + && rm -rf /opt/ibm/wlp/usr/servers/defaultServer/server.env + +COPY NOTICES /opt/ibm/NOTICES +COPY helpers/ /opt/ibm/helpers/ +COPY fixes/ /opt/ibm/fixes/ + +# Create symlinks && set permissions for non-root user +RUN mkdir /logs \ + && mkdir /etc/wlp \ + && mkdir -p /opt/ibm/wlp/usr/shared/resources/lib.index.cache \ + && mkdir -p /home/default \ + && mkdir /output \ + && chmod -t /output \ + && rm -rf /output \ + && ln -s $WLP_OUTPUT_DIR/defaultServer /output \ + && ln -s /opt/ibm/wlp/usr/servers/defaultServer /config \ + && ln -s /opt/ibm /liberty \ + && ln -s /opt/ibm/fixes /fixes \ + && ln -s /opt/ibm/wlp/usr/shared/resources/lib.index.cache /lib.index.cache \ + && mkdir -p /config/configDropins/defaults \ + && mkdir -p /config/configDropins/overrides \ + && chown -R 1001:0 /config \ + && chmod -R g+rw /config \ + && chown -R 1001:0 /opt/ibm/helpers \ + && chmod -R g+rwx /opt/ibm/helpers \ + && chown -R 1001:0 /opt/ibm/fixes \ + && chmod -R g+rwx /opt/ibm/fixes \ + && chown -R 1001:0 /opt/ibm/wlp/usr \ + && chmod -R g+rw /opt/ibm/wlp/usr \ + && chown -R 1001:0 /opt/ibm/wlp/output \ + && chmod -R g+rw /opt/ibm/wlp/output \ + && chown -R 1001:0 /logs \ + && chmod -R g+rw /logs \ + && chown -R 1001:0 /etc/wlp \ + && chmod -R g+rw /etc/wlp \ + && chown -R 1001:0 /home/default \ + && chmod -R g+rw /home/default + +# Create a new SCC layer +RUN if [ "$OPENJ9_SCC" = "true" ]; then populate_scc.sh; fi \ + && rm -rf /output/messaging /output/resources/security /logs/* $WLP_OUTPUT_DIR/.classCache \ + && chown -R 1001:0 /opt/ibm/wlp/output \ + && chmod -R g+rwx /opt/ibm/wlp/output + +# These settings are needed so that we can run as a different user than 1001 after server warmup +ENV RANDFILE=/tmp/.rnd \ + IBM_JAVA_OPTIONS="-Xshareclasses:name=liberty,readonly,nonfatal,cacheDir=/output/.classCache/ -Dosgi.checkConfiguration=false ${IBM_JAVA_OPTIONS}" + +USER 1001 + +EXPOSE 9080 9443 + +ENTRYPOINT ["/opt/ibm/helpers/runtime/docker-server.sh"] +CMD ["/opt/ibm/wlp/bin/server", "run", "defaultServer"] diff --git a/ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk11 b/ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk11 new file mode 100644 index 000000000..808d8dac3 --- /dev/null +++ b/ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk11 @@ -0,0 +1,171 @@ +# (C) Copyright IBM Corporation 2023. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +FROM ibm-semeru-runtimes:open-11-jre-focal AS getRuntime + +USER root + +ARG VERBOSE=false + +# Install WebSphere Liberty +ARG LIBERTY_VERSION=23.0.0.7 +ARG LIBERTY_URL +ARG DOWNLOAD_OPTIONS="" + +# If there is a local copy of the image use that instead +COPY resources/ /tmp/ + +RUN apt-get update \ + && apt-get install -y --no-install-recommends unzip wget openssl \ + && rm -rf /var/lib/apt/lists/* \ + && mkdir -p /licenses/ \ + && useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ + && LIBERTY_URL=${LIBERTY_URL:-$(wget -q -O - https://public.dhe.ibm.com/ibmdl/export/pub/software/websphere/wasdev/downloads/wlp/index.yml | grep -E "^\s*kernel:.*${LIBERTY_VERSION}\.zip" | sed -n 's/\s*kernel:\s//p' | tr -d '\r' )} \ + && if [ ! -f /tmp/wlp.zip ]; then wget $DOWNLOAD_OPTIONS $LIBERTY_URL -U UA-IBM-WebSphere-Liberty-Docker -O /tmp/wlp.zip; fi \ + && unzip -q /tmp/wlp.zip -d /opt/ibm \ + && chown -R 1001:0 /opt/ibm/wlp \ + && chmod -R g+rw /opt/ibm/wlp \ + && cp -a /opt/ibm/wlp/lafiles/. /licenses/ + +FROM ibm-semeru-runtimes:open-11-jre-focal + +USER root + +ARG VERBOSE=false +ARG OPENJ9_SCC=true + +ARG LIBERTY_VERSION=23.0.0.7 +ARG LIBERTY_BUILD_LABEL=cl230720230710-1201 + +LABEL org.opencontainers.image.authors="Leo Christy Jesuraj, Thomas Watson, Wendy Raschke, Michal Broz" \ + org.opencontainers.image.vendor="IBM" \ + org.opencontainers.image.url="https://github.com/WASdev/ci.docker" \ + org.opencontainers.image.documentation="https://www.ibm.com/support/knowledgecenter/SSAW57_liberty/com.ibm.websphere.wlp.nd.multiplatform.doc/ae/cwlp_about.html" \ + org.opencontainers.image.version="$LIBERTY_VERSION" \ + org.opencontainers.image.revision="$LIBERTY_BUILD_LABEL" \ + org.opencontainers.image.description="This image contains the WebSphere Liberty runtime with IBM Semeru Runtime Open Edition OpenJDK with OpenJ9 and Ubuntu as the base OS. For more information on this image please see https://ibm.biz/wl-app-image-template" \ + org.opencontainers.image.title="IBM WebSphere Liberty" + +ENV PATH=$PATH:/opt/ibm/wlp/bin:/opt/ibm/helpers/build + +# Add labels for consumption by IBM Product Insights +LABEL "ProductID"="fbf6a96d49214c0abc6a3bc5da6e48cd" \ + "ProductName"="WebSphere Application Server Liberty" \ + "ProductVersion"="$LIBERTY_VERSION" \ + "BuildLabel"="$LIBERTY_BUILD_LABEL" + +# Install dumb-init +RUN set -eux; \ + ARCH="$(dpkg --print-architecture)"; \ + case "${ARCH}" in \ + aarch64|arm64) \ + DUMB_INIT_URL='https://github.com/Yelp/dumb-init/releases/download/v1.2.5/dumb-init_1.2.5_aarch64'; \ + DUMB_INIT_SHA256=b7d648f97154a99c539b63c55979cd29f005f88430fb383007fe3458340b795e; \ + ;; \ + amd64|x86_64) \ + DUMB_INIT_URL='https://github.com/Yelp/dumb-init/releases/download/v1.2.5/dumb-init_1.2.5_x86_64'; \ + DUMB_INIT_SHA256=e874b55f3279ca41415d290c512a7ba9d08f98041b28ae7c2acb19a545f1c4df; \ + ;; \ + ppc64el|ppc64le) \ + DUMB_INIT_URL='https://github.com/Yelp/dumb-init/releases/download/v1.2.5/dumb-init_1.2.5_ppc64le'; \ + DUMB_INIT_SHA256=3d15e80e29f0f4fa1fc686b00613a2220bc37e83a35283d4b4cca1fbd0a5609f; \ + ;; \ + s390x) \ + DUMB_INIT_URL='https://github.com/Yelp/dumb-init/releases/download/v1.2.5/dumb-init_1.2.5_s390x'; \ + DUMB_INIT_SHA256=47e4601b152fc6dcb1891e66c30ecc62a2939fd7ffd1515a7c30f281cfec53b7; \ + ;;\ + *) \ + echo "Unsupported arch: ${ARCH}"; \ + exit 1; \ + ;; \ + esac; \ + curl -LfsSo /usr/bin/dumb-init ${DUMB_INIT_URL}; \ + echo "${DUMB_INIT_SHA256} */usr/bin/dumb-init" | sha256sum -c -; \ + chmod +x /usr/bin/dumb-init; + +# Add default user 1001 and create wlp with right user/permissions before copying +RUN useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ + && mkdir -p /opt/ibm/wlp \ + && chown -R 1001:0 /opt/ibm/wlp \ + && chmod -R g+rw /opt/ibm/wlp + +# Copy the runtime and licenses +COPY --from=getRuntime --chown=1001:0 /opt/ibm/wlp /opt/ibm/wlp +COPY --from=getRuntime /licenses /licenses + +RUN apt-get install -y --no-install-recommends openssl \ + && rm -rf /var/lib/apt/lists/* + +# Set Path Shortcuts +ENV LOG_DIR=/logs \ + WLP_OUTPUT_DIR=/opt/ibm/wlp/output \ + OPENJ9_SCC=$OPENJ9_SCC + +# Configure WebSphere Liberty +RUN /opt/ibm/wlp/bin/server create \ + && rm -rf $WLP_OUTPUT_DIR/.classCache /output/workarea \ + && rm -rf /opt/ibm/wlp/usr/servers/defaultServer/server.env + +COPY NOTICES /opt/ibm/NOTICES +COPY helpers/ /opt/ibm/helpers/ +COPY fixes/ /opt/ibm/fixes/ + +# Create symlinks && set permissions for non-root user +RUN mkdir /logs \ + && mkdir /etc/wlp \ + && mkdir -p /opt/ibm/wlp/usr/shared/resources/lib.index.cache \ + && mkdir -p /home/default \ + && mkdir /output \ + && chmod -t /output \ + && rm -rf /output \ + && ln -s $WLP_OUTPUT_DIR/defaultServer /output \ + && ln -s /opt/ibm/wlp/usr/servers/defaultServer /config \ + && ln -s /opt/ibm /liberty \ + && ln -s /opt/ibm/fixes /fixes \ + && ln -s /opt/ibm/wlp/usr/shared/resources/lib.index.cache /lib.index.cache \ + && mkdir -p /config/configDropins/defaults \ + && mkdir -p /config/configDropins/overrides \ + && chown -R 1001:0 /config \ + && chmod -R g+rw /config \ + && chown -R 1001:0 /opt/ibm/helpers \ + && chmod -R g+rwx /opt/ibm/helpers \ + && chown -R 1001:0 /opt/ibm/fixes \ + && chmod -R g+rwx /opt/ibm/fixes \ + && chown -R 1001:0 /opt/ibm/wlp/usr \ + && chmod -R g+rw /opt/ibm/wlp/usr \ + && chown -R 1001:0 /opt/ibm/wlp/output \ + && chmod -R g+rw /opt/ibm/wlp/output \ + && chown -R 1001:0 /logs \ + && chmod -R g+rw /logs \ + && chown -R 1001:0 /etc/wlp \ + && chmod -R g+rw /etc/wlp \ + && chown -R 1001:0 /home/default \ + && chmod -R g+rw /home/default + +# Create a new SCC layer +RUN if [ "$OPENJ9_SCC" = "true" ]; then populate_scc.sh; fi \ + && rm -rf /output/messaging /output/resources/security /logs/* $WLP_OUTPUT_DIR/.classCache \ + && chown -R 1001:0 /opt/ibm/wlp/output \ + && chmod -R g+rwx /opt/ibm/wlp/output + +# These settings are needed so that we can run as a different user than 1001 after server warmup +ENV RANDFILE=/tmp/.rnd \ + OPENJ9_JAVA_OPTIONS="-XX:+IgnoreUnrecognizedVMOptions -XX:+IdleTuningGcOnIdle -Xshareclasses:name=openj9_system_scc,cacheDir=/opt/java/.scc,readonly,nonFatal -Dosgi.checkConfiguration=false" + +USER 1001 + +EXPOSE 9080 9443 + +ENTRYPOINT ["/opt/ibm/helpers/runtime/docker-server.sh"] +CMD ["/opt/ibm/wlp/bin/server", "run", "defaultServer"] diff --git a/ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk17 b/ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk17 new file mode 100644 index 000000000..f0bc89464 --- /dev/null +++ b/ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk17 @@ -0,0 +1,171 @@ +# (C) Copyright IBM Corporation 2023. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +FROM ibm-semeru-runtimes:open-17-jre-focal AS getRuntime + +USER root + +ARG VERBOSE=false + +# Install WebSphere Liberty +ARG LIBERTY_VERSION=23.0.0.7 +ARG LIBERTY_URL +ARG DOWNLOAD_OPTIONS="" + +# If there is a local copy of the image use that instead +COPY resources/ /tmp/ + +RUN apt-get update \ + && apt-get install -y --no-install-recommends unzip wget openssl \ + && rm -rf /var/lib/apt/lists/* \ + && mkdir -p /licenses/ \ + && useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ + && LIBERTY_URL=${LIBERTY_URL:-$(wget -q -O - https://public.dhe.ibm.com/ibmdl/export/pub/software/websphere/wasdev/downloads/wlp/index.yml | grep -E "^\s*kernel:.*${LIBERTY_VERSION}\.zip" | sed -n 's/\s*kernel:\s//p' | tr -d '\r' )} \ + && if [ ! -f /tmp/wlp.zip ]; then wget $DOWNLOAD_OPTIONS $LIBERTY_URL -U UA-IBM-WebSphere-Liberty-Docker -O /tmp/wlp.zip; fi \ + && unzip -q /tmp/wlp.zip -d /opt/ibm \ + && chown -R 1001:0 /opt/ibm/wlp \ + && chmod -R g+rw /opt/ibm/wlp \ + && cp -a /opt/ibm/wlp/lafiles/. /licenses/ + +FROM ibm-semeru-runtimes:open-17-jre-focal + +USER root + +ARG VERBOSE=false +ARG OPENJ9_SCC=true + +ARG LIBERTY_VERSION=23.0.0.7 +ARG LIBERTY_BUILD_LABEL=cl230720230710-1201 + +LABEL org.opencontainers.image.authors="Leo Christy Jesuraj, Thomas Watson, Wendy Raschke, Michal Broz" \ + org.opencontainers.image.vendor="IBM" \ + org.opencontainers.image.url="https://github.com/WASdev/ci.docker" \ + org.opencontainers.image.documentation="https://www.ibm.com/support/knowledgecenter/SSAW57_liberty/com.ibm.websphere.wlp.nd.multiplatform.doc/ae/cwlp_about.html" \ + org.opencontainers.image.version="$LIBERTY_VERSION" \ + org.opencontainers.image.revision="$LIBERTY_BUILD_LABEL" \ + org.opencontainers.image.description="This image contains the WebSphere Liberty runtime with IBM Semeru Runtime Open Edition OpenJDK with OpenJ9 and Ubuntu as the base OS. For more information on this image please see https://ibm.biz/wl-app-image-template" \ + org.opencontainers.image.title="IBM WebSphere Liberty" + +ENV PATH=$PATH:/opt/ibm/wlp/bin:/opt/ibm/helpers/build + +# Add labels for consumption by IBM Product Insights +LABEL "ProductID"="fbf6a96d49214c0abc6a3bc5da6e48cd" \ + "ProductName"="WebSphere Application Server Liberty" \ + "ProductVersion"="$LIBERTY_VERSION" \ + "BuildLabel"="$LIBERTY_BUILD_LABEL" + +# Install dumb-init +RUN set -eux; \ + ARCH="$(dpkg --print-architecture)"; \ + case "${ARCH}" in \ + aarch64|arm64) \ + DUMB_INIT_URL='https://github.com/Yelp/dumb-init/releases/download/v1.2.5/dumb-init_1.2.5_aarch64'; \ + DUMB_INIT_SHA256=b7d648f97154a99c539b63c55979cd29f005f88430fb383007fe3458340b795e; \ + ;; \ + amd64|x86_64) \ + DUMB_INIT_URL='https://github.com/Yelp/dumb-init/releases/download/v1.2.5/dumb-init_1.2.5_x86_64'; \ + DUMB_INIT_SHA256=e874b55f3279ca41415d290c512a7ba9d08f98041b28ae7c2acb19a545f1c4df; \ + ;; \ + ppc64el|ppc64le) \ + DUMB_INIT_URL='https://github.com/Yelp/dumb-init/releases/download/v1.2.5/dumb-init_1.2.5_ppc64le'; \ + DUMB_INIT_SHA256=3d15e80e29f0f4fa1fc686b00613a2220bc37e83a35283d4b4cca1fbd0a5609f; \ + ;; \ + s390x) \ + DUMB_INIT_URL='https://github.com/Yelp/dumb-init/releases/download/v1.2.5/dumb-init_1.2.5_s390x'; \ + DUMB_INIT_SHA256=47e4601b152fc6dcb1891e66c30ecc62a2939fd7ffd1515a7c30f281cfec53b7; \ + ;;\ + *) \ + echo "Unsupported arch: ${ARCH}"; \ + exit 1; \ + ;; \ + esac; \ + curl -LfsSo /usr/bin/dumb-init ${DUMB_INIT_URL}; \ + echo "${DUMB_INIT_SHA256} */usr/bin/dumb-init" | sha256sum -c -; \ + chmod +x /usr/bin/dumb-init; + +# Add default user 1001 and create wlp with right user/permissions before copying +RUN useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ + && mkdir -p /opt/ibm/wlp \ + && chown -R 1001:0 /opt/ibm/wlp \ + && chmod -R g+rw /opt/ibm/wlp + +# Copy the runtime and licenses +COPY --from=getRuntime --chown=1001:0 /opt/ibm/wlp /opt/ibm/wlp +COPY --from=getRuntime /licenses /licenses + +RUN apt-get install -y --no-install-recommends openssl \ + && rm -rf /var/lib/apt/lists/* + +# Set Path Shortcuts +ENV LOG_DIR=/logs \ + WLP_OUTPUT_DIR=/opt/ibm/wlp/output \ + OPENJ9_SCC=$OPENJ9_SCC + +# Configure WebSphere Liberty +RUN /opt/ibm/wlp/bin/server create \ + && rm -rf $WLP_OUTPUT_DIR/.classCache /output/workarea \ + && rm -rf /opt/ibm/wlp/usr/servers/defaultServer/server.env + +COPY NOTICES /opt/ibm/NOTICES +COPY helpers/ /opt/ibm/helpers/ +COPY fixes/ /opt/ibm/fixes/ + +# Create symlinks && set permissions for non-root user +RUN mkdir /logs \ + && mkdir /etc/wlp \ + && mkdir -p /opt/ibm/wlp/usr/shared/resources/lib.index.cache \ + && mkdir -p /home/default \ + && mkdir /output \ + && chmod -t /output \ + && rm -rf /output \ + && ln -s $WLP_OUTPUT_DIR/defaultServer /output \ + && ln -s /opt/ibm/wlp/usr/servers/defaultServer /config \ + && ln -s /opt/ibm /liberty \ + && ln -s /opt/ibm/fixes /fixes \ + && ln -s /opt/ibm/wlp/usr/shared/resources/lib.index.cache /lib.index.cache \ + && mkdir -p /config/configDropins/defaults \ + && mkdir -p /config/configDropins/overrides \ + && chown -R 1001:0 /config \ + && chmod -R g+rw /config \ + && chown -R 1001:0 /opt/ibm/helpers \ + && chmod -R g+rwx /opt/ibm/helpers \ + && chown -R 1001:0 /opt/ibm/fixes \ + && chmod -R g+rwx /opt/ibm/fixes \ + && chown -R 1001:0 /opt/ibm/wlp/usr \ + && chmod -R g+rw /opt/ibm/wlp/usr \ + && chown -R 1001:0 /opt/ibm/wlp/output \ + && chmod -R g+rw /opt/ibm/wlp/output \ + && chown -R 1001:0 /logs \ + && chmod -R g+rw /logs \ + && chown -R 1001:0 /etc/wlp \ + && chmod -R g+rw /etc/wlp \ + && chown -R 1001:0 /home/default \ + && chmod -R g+rw /home/default + +# Create a new SCC layer +RUN if [ "$OPENJ9_SCC" = "true" ]; then populate_scc.sh; fi \ + && rm -rf /output/messaging /output/resources/security /logs/* $WLP_OUTPUT_DIR/.classCache \ + && chown -R 1001:0 /opt/ibm/wlp/output \ + && chmod -R g+rwx /opt/ibm/wlp/output + +# These settings are needed so that we can run as a different user than 1001 after server warmup +ENV RANDFILE=/tmp/.rnd \ + OPENJ9_JAVA_OPTIONS="-XX:+IgnoreUnrecognizedVMOptions -XX:+IdleTuningGcOnIdle -Xshareclasses:name=openj9_system_scc,cacheDir=/opt/java/.scc,readonly,nonFatal -Dosgi.checkConfiguration=false" + +USER 1001 + +EXPOSE 9080 9443 + +ENTRYPOINT ["/opt/ibm/helpers/runtime/docker-server.sh"] +CMD ["/opt/ibm/wlp/bin/server", "run", "defaultServer"] diff --git a/ga/23.0.0.7/kernel/NOTICES b/ga/23.0.0.7/kernel/NOTICES new file mode 100644 index 000000000..474e8d98e --- /dev/null +++ b/ga/23.0.0.7/kernel/NOTICES @@ -0,0 +1,72 @@ +NOTICES AND INFORMATION + +IBM WebSphere Application Server Liberty @LIBERTY_VERSION@ + +The IBM license agreement and any applicable information on the web +download page for IBM products refers Licensee to this file for details +concerning notices applicable to code included in the products listed +above ("the Program"). + +Notwithstanding the terms and conditions of any other agreement Licensee +may have with IBM or any of its related or affiliated entities +(collectively "IBM"), the third party code identified below is subject +to the terms and conditions of the IBM license agreement for the Program +and not the license terms that may be contained in the notices below. +The notices are provided for informational purposes. + +Please note: This Notices file may identify information that is not used +by, or that was not shipped with, the Program as Licensee installed it. + +IMPORTANT: IBM does not represent or warrant that the information in this +NOTICES file is accurate. Third party websites are independent of IBM and +IBM does not represent or warrant that the information on any third party +website referenced in this NOTICES file is accurate. IBM disclaims any +and all liability for errors and omissions or for any damages accruing +from the use of this NOTICES file or its contents, including without +limitation URLs or references to any third party websites. + +TABLE OF CONTENTS + +THIS IBM NOTICES FILE CONSISTS OF THE FOLLOWING SECTIONS: +MIT + +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + +MIT LICENSE + +The Program includes some or all of the following that IBM obtained +under the MIT License: + +DUMB_INIT Copyright (c) 2015 Yelp, Inc. + +Permission is hereby granted, free of charge, to any person obtaining a +copy of this software and associated documentation files (the +"Software"), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be included +in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. +IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY +CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, +TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE +SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +END OF MIT LICENSE NOTICES AND INFORMATION +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + +END OF NOTICES AND INFORMATION +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + + +END OF NOTICES AND INFORMATION FOR +IBM WebSphere Application Server Liberty @LIBERTY_VERSION@ +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + + diff --git a/ga/23.0.0.7/kernel/README.md b/ga/23.0.0.7/kernel/README.md new file mode 100644 index 000000000..32ce7911c --- /dev/null +++ b/ga/23.0.0.7/kernel/README.md @@ -0,0 +1,9 @@ +# WebSphere Application Server Developer Edition Liberty kernel image + +The [Dockerfile.ubuntu.ibmjava8](Dockerfile.ubuntu.ibmjava8) in this directory is used to build the `websphere-liberty:kernel` image on [Docker Hub](https://registry.hub.docker.com/_/websphere-liberty/). The image contains IBM WebSphere Application Server Developer Edition Liberty Kernel and an IBM Java Runtime Environment. + +# Usage + +Instructions for using the image can be found on [Docker Hub](https://registry.hub.docker.com/_/websphere-liberty/). It is possible to build the image yourself by cloning this repository, changing to the `ga//kernel` directory and then issuing the command to build container image. For example, with Docker execute `docker build .`. + +**Note:** Refer to [Optional Enterprise Functionality](https://github.com/WASdev/ci.docker#optional-enterprise-functionality) to ensure certain features are enabled such as monitoring or SSL. diff --git a/ga/23.0.0.7/kernel/fixes/.gitkeep b/ga/23.0.0.7/kernel/fixes/.gitkeep new file mode 100644 index 000000000..a282fd264 --- /dev/null +++ b/ga/23.0.0.7/kernel/fixes/.gitkeep @@ -0,0 +1,2 @@ +Place holder file to keep the fixes directory +in git even if there aren't any current ifixes. diff --git a/ga/23.0.0.7/kernel/helpers/build/checkpoint.sh b/ga/23.0.0.7/kernel/helpers/build/checkpoint.sh new file mode 100755 index 000000000..dba7820ff --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/checkpoint.sh @@ -0,0 +1,13 @@ +#!/bin/bash + +# hack to bump up the pid by 100 +for i in {1..100} +do + pidplus.sh +done + +echo "Performing checkpoint --at=$1" +/opt/ibm/wlp/bin/server checkpoint defaultServer --at=$1 + +rc=$? +exit $rc diff --git a/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/hazelcast-client.xml b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/hazelcast-client.xml new file mode 100644 index 000000000..61dddfce0 --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/hazelcast-client.xml @@ -0,0 +1,16 @@ + + + + true + + + true + + + + + + diff --git a/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/hazelcast-embedded.xml b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/hazelcast-embedded.xml new file mode 100644 index 000000000..4dd8f8063 --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/hazelcast-embedded.xml @@ -0,0 +1,19 @@ + + + + true + + + + + + + + + + + + diff --git a/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/hazelcast-sessioncache-config.xml b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/hazelcast-sessioncache-config.xml new file mode 100644 index 000000000..ce9fa0d76 --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/hazelcast-sessioncache-config.xml @@ -0,0 +1,8 @@ + + + + + + + + \ No newline at end of file diff --git a/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/hazelcast-sessioncache.xml b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/hazelcast-sessioncache.xml new file mode 100644 index 000000000..db8dc6a47 --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/hazelcast-sessioncache.xml @@ -0,0 +1,11 @@ + + + sessionCache-1.0 + + + + + + + + \ No newline at end of file diff --git a/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/http-endpoint.xml b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/http-endpoint.xml new file mode 100644 index 000000000..5f6c60552 --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/http-endpoint.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/http-ssl-endpoint.xml b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/http-ssl-endpoint.xml new file mode 100644 index 000000000..2a2388a3c --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/http-ssl-endpoint.xml @@ -0,0 +1,6 @@ + + + + + + diff --git a/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/iiop-endpoint.xml b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/iiop-endpoint.xml new file mode 100644 index 000000000..a5b7d8a0c --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/iiop-endpoint.xml @@ -0,0 +1,5 @@ + + + + + \ No newline at end of file diff --git a/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/iiop-ssl-endpoint.xml b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/iiop-ssl-endpoint.xml new file mode 100644 index 000000000..f8fea3c88 --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/iiop-ssl-endpoint.xml @@ -0,0 +1,8 @@ + + + + + + + + \ No newline at end of file diff --git a/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/infinispan-client-sessioncache-config.xml b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/infinispan-client-sessioncache-config.xml new file mode 100644 index 000000000..d835cb4e9 --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/infinispan-client-sessioncache-config.xml @@ -0,0 +1,16 @@ + + + + + + + + + + + + + + + + diff --git a/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/infinispan-client-sessioncache.xml b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/infinispan-client-sessioncache.xml new file mode 100644 index 000000000..e2ec72d2c --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/infinispan-client-sessioncache.xml @@ -0,0 +1,19 @@ + + + sessionCache-1.0 + + + + + + + + + + + + + + + + diff --git a/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/jms-endpoint.xml b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/jms-endpoint.xml new file mode 100644 index 000000000..a99b07165 --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/jms-endpoint.xml @@ -0,0 +1,5 @@ + + + + + \ No newline at end of file diff --git a/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/jms-ssl-endpoint.xml b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/jms-ssl-endpoint.xml new file mode 100644 index 000000000..d32a77ce7 --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/jms-ssl-endpoint.xml @@ -0,0 +1,5 @@ + + + + + \ No newline at end of file diff --git a/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/keystore.xml b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/keystore.xml new file mode 100644 index 000000000..d4872b5ce --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/keystore.xml @@ -0,0 +1,3 @@ + + + \ No newline at end of file diff --git a/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/mp-health-check.xml b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/mp-health-check.xml new file mode 100644 index 000000000..874559d63 --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/mp-health-check.xml @@ -0,0 +1,6 @@ + + + + mpHealth-1.0 + + \ No newline at end of file diff --git a/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/mp-monitoring.xml b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/mp-monitoring.xml new file mode 100644 index 000000000..4f5b0ce08 --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/mp-monitoring.xml @@ -0,0 +1,9 @@ + + + + mpMetrics-1.1 + monitor-1.0 + + + + diff --git a/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/oidc-config.xml b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/oidc-config.xml new file mode 100644 index 000000000..976afbe4b --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/oidc-config.xml @@ -0,0 +1,8 @@ + + + + + diff --git a/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/oidc.xml b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/oidc.xml new file mode 100644 index 000000000..f044723be --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/oidc.xml @@ -0,0 +1,6 @@ + + + + openidConnectClient-1.0 + + diff --git a/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sessioncache-features.xml b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sessioncache-features.xml new file mode 100644 index 000000000..f7b5a4685 --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sessioncache-features.xml @@ -0,0 +1,5 @@ + + + sessionCache-1.0 + + \ No newline at end of file diff --git a/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sso-facebook.xml b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sso-facebook.xml new file mode 100644 index 000000000..0c2d8aa42 --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sso-facebook.xml @@ -0,0 +1,19 @@ + + + + + + + + + \ No newline at end of file diff --git a/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sso-features.xml b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sso-features.xml new file mode 100644 index 000000000..a26c00a58 --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sso-features.xml @@ -0,0 +1,7 @@ + + + + appSecurity-2.0 + socialLogin-1.0 + + \ No newline at end of file diff --git a/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sso-github.xml b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sso-github.xml new file mode 100644 index 000000000..1e96a50aa --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sso-github.xml @@ -0,0 +1,24 @@ + + + + + + + + + + \ No newline at end of file diff --git a/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sso-google.xml b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sso-google.xml new file mode 100644 index 000000000..50b40143f --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sso-google.xml @@ -0,0 +1,19 @@ + + + + + + + + + \ No newline at end of file diff --git a/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sso-linkedin.xml b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sso-linkedin.xml new file mode 100644 index 000000000..f608d5cbb --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sso-linkedin.xml @@ -0,0 +1,19 @@ + + + + + + + + + \ No newline at end of file diff --git a/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sso-oauth2.xml b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sso-oauth2.xml new file mode 100644 index 000000000..783ce2d95 --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sso-oauth2.xml @@ -0,0 +1,51 @@ + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sso-oidc.xml b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sso-oidc.xml new file mode 100644 index 000000000..530465305 --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sso-oidc.xml @@ -0,0 +1,38 @@ + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sso-twitter.xml b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sso-twitter.xml new file mode 100644 index 000000000..aedffbb50 --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/sso-twitter.xml @@ -0,0 +1,17 @@ + + + + + + + + \ No newline at end of file diff --git a/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/tls.xml b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/tls.xml new file mode 100644 index 000000000..9d6838900 --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/tls.xml @@ -0,0 +1,5 @@ + + + transportSecurity-1.0 + + \ No newline at end of file diff --git a/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/trustDefault.xml b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/trustDefault.xml new file mode 100644 index 000000000..396987fad --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/trustDefault.xml @@ -0,0 +1,4 @@ + + + + diff --git a/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/truststore.xml b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/truststore.xml new file mode 100644 index 000000000..3a32393d3 --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/configuration_snippets/truststore.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/ga/23.0.0.7/kernel/helpers/build/configure.sh b/ga/23.0.0.7/kernel/helpers/build/configure.sh new file mode 100755 index 000000000..b2480a5cd --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/configure.sh @@ -0,0 +1,219 @@ +#!/bin/bash +# (C) Copyright IBM Corporation 2020, 2023. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Determine if featureUtility ran in an earlier build step +if /opt/ibm/helpers/build/internal/features-installed.sh; then + FEATURES_INSTALLED=true +else + FEATURES_INSTALLED=false +fi + +if [ "$VERBOSE" != "true" ]; then + exec &>/dev/null +fi + +set -Eeox pipefail + +function main() { + ##Define variables for XML snippets source and target paths + WLP_INSTALL_DIR=/opt/ibm/wlp + SHARED_CONFIG_DIR=${WLP_INSTALL_DIR}/usr/shared/config + SHARED_RESOURCE_DIR=${WLP_INSTALL_DIR}/usr/shared/resources + + SNIPPETS_SOURCE=/opt/ibm/helpers/build/configuration_snippets + SNIPPETS_TARGET=/config/configDropins/overrides + SNIPPETS_TARGET_DEFAULTS=/config/configDropins/defaults + mkdir -p ${SNIPPETS_TARGET} + mkdir -p ${SNIPPETS_TARGET_DEFAULTS} + + # Check for each Liberty value-add functionality + if [ "$FEATURES_INSTALLED" == "false" ]; then + # HTTP Endpoint + if [ "$HTTP_ENDPOINT" == "true" ]; then + if [ "$SSL" == "true" ] || [ "$TLS" == "true" ]; then + cp $SNIPPETS_SOURCE/http-ssl-endpoint.xml $SNIPPETS_TARGET/http-ssl-endpoint.xml + else + cp $SNIPPETS_SOURCE/http-endpoint.xml $SNIPPETS_TARGET/http-endpoint.xml + fi + fi + + # MicroProfile Health + if [ "$MP_HEALTH_CHECK" == "true" ]; then + cp $SNIPPETS_SOURCE/mp-health-check.xml $SNIPPETS_TARGET/mp-health-check.xml + fi + + # MicroProfile Monitoring + if [ "$MP_MONITORING" == "true" ]; then + cp $SNIPPETS_SOURCE/mp-monitoring.xml $SNIPPETS_TARGET/mp-monitoring.xml + fi + + # IIOP Endpoint + if [ "$IIOP_ENDPOINT" == "true" ]; then + if [ "$SSL" == "true" ] || [ "$TLS" == "true" ]; then + cp $SNIPPETS_SOURCE/iiop-ssl-endpoint.xml $SNIPPETS_TARGET/iiop-ssl-endpoint.xml + else + cp $SNIPPETS_SOURCE/iiop-endpoint.xml $SNIPPETS_TARGET/iiop-endpoint.xml + fi + fi + + # JMS Endpoint + if [ "$JMS_ENDPOINT" == "true" ]; then + if [ "$SSL" == "true" ] || [ "$TLS" == "true" ]; then + cp $SNIPPETS_SOURCE/jms-ssl-endpoint.xml $SNIPPETS_TARGET/jms-ssl-endpoint.xml + else + cp $SNIPPETS_SOURCE/jms-endpoint.xml $SNIPPETS_TARGET/jms-endpoint.xml + fi + fi + + # OpenIdConnect Client + if [ "$OIDC" == "true" ] || [ "$OIDC_CONFIG" == "true" ]; then + cp $SNIPPETS_SOURCE/oidc.xml $SNIPPETS_TARGET/oidc.xml + fi + if [ "$OIDC_CONFIG" == "true" ]; then + cp $SNIPPETS_SOURCE/oidc-config.xml $SNIPPETS_TARGET/oidc-config.xml + fi + + # Infinispan Session Caching (Full) + if [[ -n "$INFINISPAN_SERVICE_NAME" ]]; then + cp ${SNIPPETS_SOURCE}/infinispan-client-sessioncache.xml ${SNIPPETS_TARGET}/infinispan-client-sessioncache.xml + chmod g+rw $SNIPPETS_TARGET/infinispan-client-sessioncache.xml + fi + + # Hazelcast Session Caching (Full) + if [ "${HZ_SESSION_CACHE}" == "client" ] || [ "${HZ_SESSION_CACHE}" == "embedded" ]; then + cp ${SNIPPETS_SOURCE}/hazelcast-sessioncache.xml ${SNIPPETS_TARGET}/hazelcast-sessioncache.xml + mkdir -p ${SHARED_CONFIG_DIR}/hazelcast + cp ${SNIPPETS_SOURCE}/hazelcast-${HZ_SESSION_CACHE}.xml ${SHARED_CONFIG_DIR}/hazelcast/hazelcast.xml + fi + + # SSO + if [[ -n "$SEC_SSO_PROVIDERS" ]]; then + cp $SNIPPETS_SOURCE/sso-features.xml $SNIPPETS_TARGET_DEFAULTS + fi + + # Key Store + if [ "$SSL" == "true" ] || [ "$TLS" == "true" ]; then + cp $SNIPPETS_SOURCE/tls.xml $SNIPPETS_TARGET/tls.xml + fi + else + # Otherwise, load XML for addons that have features already installed + # Infinispan Session Caching + if [[ -n "$INFINISPAN_SERVICE_NAME" ]]; then + cp ${SNIPPETS_SOURCE}/infinispan-client-sessioncache-config.xml ${SNIPPETS_TARGET}/infinispan-client-sessioncache-config.xml + chmod g+rw $SNIPPETS_TARGET/infinispan-client-sessioncache-config.xml + fi + + # Hazelcast Session Caching + if [ "${HZ_SESSION_CACHE}" == "client" ] || [ "${HZ_SESSION_CACHE}" == "embedded" ]; then + cp ${SNIPPETS_SOURCE}/hazelcast-sessioncache-config.xml ${SNIPPETS_TARGET}/hazelcast-sessioncache-config.xml + mkdir -p ${SHARED_CONFIG_DIR}/hazelcast + cp ${SNIPPETS_SOURCE}/hazelcast-${HZ_SESSION_CACHE}.xml ${SHARED_CONFIG_DIR}/hazelcast/hazelcast.xml + fi + fi + + # Key Store + keystorePath="$SNIPPETS_TARGET_DEFAULTS/keystore.xml" + if [ "$SSL" != "false" ] && [ "$TLS" != "false" ]; then + if [ ! -e $keystorePath ]; then + # Generate the keystore.xml + export KEYSTOREPWD=$(openssl rand -base64 32) + sed "s|REPLACE|$KEYSTOREPWD|g" $SNIPPETS_SOURCE/keystore.xml > $SNIPPETS_TARGET_DEFAULTS/keystore.xml + chmod g+w $SNIPPETS_TARGET_DEFAULTS/keystore.xml + fi + fi + + # SSO + if [[ -n "$SEC_SSO_PROVIDERS" ]]; then + parseProviders $SEC_SSO_PROVIDERS + fi + + if [ "$SKIP_FEATURE_INSTALL" != "true" ] && [ "$FEATURES_INSTALLED" == "false" ]; then + # Install needed features + if [ "$FEATURE_REPO_URL" ]; then + curl -k --fail $FEATURE_REPO_URL > /tmp/repo.zip + installUtility install --acceptLicense defaultServer --from=/tmp/repo.zip || rc=$?; if [ $rc -ne 22 ]; then exit $rc; fi + rm -rf /tmp/repo.zip + else + installUtility install --acceptLicense defaultServer || rc=$?; if [ $rc -ne 22 ]; then exit $rc; fi + fi + fi + + # Apply interim fixes found in /opt/ibm/fixes + # Fixes recommended by IBM, such as to resolve security vulnerabilities, are also included in /opt/ibm/fixes + # Note: This step should be done once needed features are enabled and installed using installUtility. + + # Do not create a SCC + if [ -n "${IBM_JAVA_OPTIONS}" ]; then + IBM_JAVA_OPTIONS="${IBM_JAVA_OPTIONS} -Xshareclasses:none" + fi + + if [ -n "${OPENJ9_JAVA_OPTIONS}" ]; then + OPENJ9_JAVA_OPTIONS="${OPENJ9_JAVA_OPTIONS} -Xshareclasses:none" + fi + + find /opt/ibm/fixes -type f -name "*.jar" -print0 | sort -z | xargs -0 -n 1 -r -I {} java -jar {} --installLocation $WLP_INSTALL_DIR + #Make sure that group write permissions are set correctly after installing new features + find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw + + # Create a new SCC layer + if [ "$OPENJ9_SCC" == "true" ]; then + cmd="populate_scc.sh -i 1" + if [ "$TRIM_SCC" == "false" ]; then + cmd+=" -d" + fi + if [ ! "$SCC_SIZE" = "" ]; then + cmd+=" -s $SCC_SIZE" + fi + eval $cmd + fi +} + +## parse provider list to generate files into configDropins +function parseProviders() { + while [ $# -gt 0 ]; do + case "$1" in + oidc:*) + parseCommaList oidc "${1#*:}" + ;; + oauth2:*) + parseCommaList oauth2 "${1#*:}" + ;; + *) + if [[ $(ls $SNIPPETS_SOURCE | grep "$1") ]]; then + cp $SNIPPETS_SOURCE/sso-${1}.xml $SNIPPETS_TARGET_DEFAULTS + fi + ;; + esac + shift + done +} + +## process the comma delimitted oauth2/oidc source lists +function parseCommaList() { + local type="$1" + local list=$(echo "$2" | tr , " ") + + for current in ${list}; do + if [[ "${type}" = "oidc" ]]; then + # replace oidc identifiers with custom name + sed -e 's/=\"oidc/=\"'${current}'/g' -e 's/_OIDC_/_'${current^^}'_/g' $SNIPPETS_SOURCE/sso-oidc.xml > $SNIPPETS_TARGET_DEFAULTS/sso-${current}.xml + else + # replace oauth2 identifiers with custom name + sed -e 's/=\"oauth2/=\"'${current}'/g' -e 's/_OAUTH2_/_'${current^^}'_/g' $SNIPPETS_SOURCE/sso-oauth2.xml > $SNIPPETS_TARGET_DEFAULTS/sso-${current}.xml + fi + done +} + +main "$@" diff --git a/ga/23.0.0.7/kernel/helpers/build/features.sh b/ga/23.0.0.7/kernel/helpers/build/features.sh new file mode 100755 index 000000000..4e6654898 --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/features.sh @@ -0,0 +1,48 @@ +#!/bin/bash +# (C) Copyright IBM Corporation 2023. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +if [ "$VERBOSE" != "true" ]; then + exec &>/dev/null +fi + +set -Eeox pipefail + +##Define variables for XML snippets source and target paths +SNIPPETS_SOURCE=/opt/ibm/helpers/build/configuration_snippets +SNIPPETS_TARGET=/config/configDropins/overrides +SNIPPETS_TARGET_DEFAULTS=/config/configDropins/defaults +mkdir -p ${SNIPPETS_TARGET} +mkdir -p ${SNIPPETS_TARGET_DEFAULTS} + +# Session Caching +if [ -n "$INFINISPAN_SERVICE_NAME" ] || [ "${HZ_SESSION_CACHE}" == "client" ] || [ "${HZ_SESSION_CACHE}" == "embedded" ]; then + cp ${SNIPPETS_SOURCE}/sessioncache-features.xml ${SNIPPETS_TARGET}/sessioncache-features.xml + chmod g+rw $SNIPPETS_TARGET/sessioncache-features.xml +fi + +# SSO +if [[ -n "$SEC_SSO_PROVIDERS" ]]; then + cp $SNIPPETS_SOURCE/sso-features.xml $SNIPPETS_TARGET_DEFAULTS +fi + +# Key Store +if [ "$SSL" == "true" ] || [ "$TLS" == "true" ]; then + cp $SNIPPETS_SOURCE/tls.xml $SNIPPETS_TARGET/tls.xml +fi + +# Install necessary features using featureUtility +featureUtility installServerFeatures --acceptLicense defaultServer --noCache +find /opt/ibm/wlp/lib /opt/ibm/wlp/bin ! -perm -g=rw -print0 | xargs -0 -r chmod g+rw + +echo "features.sh script has been run" > /logs/features.log diff --git a/ga/23.0.0.7/kernel/helpers/build/infinispan-client-setup.sh b/ga/23.0.0.7/kernel/helpers/build/infinispan-client-setup.sh new file mode 100755 index 000000000..cf54d05df --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/infinispan-client-setup.sh @@ -0,0 +1,35 @@ +#!/bin/bash +# (C) Copyright IBM Corporation 2020. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +if [ "$VERBOSE" != "true" ]; then + exec &>/dev/null +fi + +set -Eeox pipefail + +yum update -y +yum install -y maven +mkdir -p /opt/ibm/wlp/usr/shared/resources/infinispan +echo ' 4.0.0 io.openliberty openliberty-infinispan-client 1.0 org.infinispan infinispan-jcache-remote 10.1.3.Final ' > /opt/ibm/wlp/usr/shared/resources/infinispan/pom.xml +mvn -f /opt/ibm/wlp/usr/shared/resources/infinispan/pom.xml versions:use-latest-releases -DallowMajorUpdates=false +mvn -f /opt/ibm/wlp/usr/shared/resources/infinispan/pom.xml dependency:copy-dependencies -DoutputDirectory=/opt/ibm/wlp/usr/shared/resources/infinispan +yum remove -y maven +rm -f /opt/ibm/wlp/usr/shared/resources/infinispan/pom.xml +rm -f /opt/ibm/wlp/usr/shared/resources/infinispan/jboss-transaction-api*.jar +rm -f /opt/ibm/wlp/usr/shared/resources/infinispan/reactive-streams-*.jar +rm -f /opt/ibm/wlp/usr/shared/resources/infinispan/rxjava-*.jar +rm -rf ~/.m2 +chown -R 1001:0 /opt/ibm/wlp/usr/shared/resources/infinispan +chmod -R g+rw /opt/ibm/wlp/usr/shared/resources/infinispan + diff --git a/ga/23.0.0.7/kernel/helpers/build/internal/features-installed.sh b/ga/23.0.0.7/kernel/helpers/build/internal/features-installed.sh new file mode 100755 index 000000000..c32ac59f4 --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/internal/features-installed.sh @@ -0,0 +1,9 @@ +#!/bin/bash + +if [ -f "/logs/features.log" ]; then + rm /logs/features.log + exit 0 +fi + +>&2 echo "WARNING: This is not an optimal build configuration. Although features in server.xml will continue to be installed correctly, the 'RUN features.sh' command should be added to the Dockerfile prior to configure.sh. See https://ibm.biz/wl-app-image-template for a sample application image template." +exit 1 diff --git a/ga/23.0.0.7/kernel/helpers/build/pidplus.sh b/ga/23.0.0.7/kernel/helpers/build/pidplus.sh new file mode 100755 index 000000000..ad8007957 --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/pidplus.sh @@ -0,0 +1,6 @@ +#!/bin/bash + +# hack to bump up the pid +echo "nothing" > /dev/null + + diff --git a/ga/23.0.0.7/kernel/helpers/build/populate_scc.sh b/ga/23.0.0.7/kernel/helpers/build/populate_scc.sh new file mode 100755 index 000000000..8f65ec392 --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/build/populate_scc.sh @@ -0,0 +1,138 @@ +#!/bin/bash +# (C) Copyright IBM Corporation 2020. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +if [ "$VERBOSE" != "true" ]; then + exec &>/dev/null +fi + +set -Eeox pipefail + +# 32-bit JVMs don't supported multi-layered SCCs. +[ -e "$JAVA_HOME/lib/i386" -o -e "$JAVA_HOME/lib/ppc" -o -e "$JAVA_HOME/lib/s390" ] && exit 0 + +SCC_SIZE="80m" # Default size of the SCC layer. +ITERATIONS=2 # Number of iterations to run to populate it. +TRIM_SCC=yes # Trim the SCC to eliminate any wasted space. + +# If this directory exists and has at least ug=rwx permissions, assume the base image includes an SCC called 'openj9_system_scc' and build on it. +# If not, build on our own SCC. +if [[ -d "/opt/java/.scc" ]] && [[ `stat -L -c "%a" "/opt/java/.scc" | cut -c 1,2` == "77" ]] +then + SCC="-Xshareclasses:name=openj9_system_scc,cacheDir=/opt/java/.scc" +else + SCC="-Xshareclasses:name=liberty,cacheDir=/output/.classCache" +fi + +# For JDK8, as of OpenJ9 0.20.0 the criteria for determining the max heap size (-Xmx) has changed +# and the JVM has freedom to choose larger max heap sizes. +# Currently in compressedrefs mode there is a dependency between heap size and position and the AOT code stored in the +# SCC, such that if the max heap size/position changes too drastically the AOT code in the SCC becomes invalid and will +# not be loaded. Also, new AOT code will not be generated. +# In order to reduce the chances of this happening we use the -XX:+OriginalJDK8HeapSizeCompatibilityMode +# option to revert to the old criteria, which results in AOT code that is more compatible, on average, with typical heap sizes/positions. +# The option has no effect on later JDKs. +export OPENJ9_JAVA_OPTIONS="-XX:+OriginalJDK8HeapSizeCompatibilityMode $SCC" +export IBM_JAVA_OPTIONS="$OPENJ9_JAVA_OPTIONS" +CREATE_LAYER="$OPENJ9_JAVA_OPTIONS,createLayer,groupAccess" +DESTROY_LAYER="$OPENJ9_JAVA_OPTIONS,destroy" +PRINT_LAYER_STATS="$OPENJ9_JAVA_OPTIONS,printTopLayerStats" + +while getopts ":i:s:tdh" OPT +do + case "$OPT" in + i) + ITERATIONS="$OPTARG" + ;; + s) + [ "${OPTARG: -1}" == "m" ] || ( echo "Missing m suffix." && exit 1 ) + SCC_SIZE="$OPTARG" + ;; + t) + TRIM_SCC=yes + ;; + d) + TRIM_SCC=no + ;; + h) + echo \ +"Usage: $0 [-i iterations] [-s size] [-t] [-d] + -i Number of iterations to run to populate the SCC. (Default: $ITERATIONS) + -s Size of the SCC in megabytes (m suffix required). (Default: $SCC_SIZE) + -t Trim the SCC to eliminate most of the free space, if any. + -d Don't trim the SCC. + + Trimming enabled=$TRIM_SCC" + exit 1 + ;; + \?) + echo "Unrecognized option: $OPTARG" 1>&2 + exit 1 + ;; + :) + echo "Missing argument for option: $OPTARG" 1>&2 + exit 1 + ;; + esac +done + +OLD_UMASK=`umask` +umask 002 # 002 is required to provide group rw permission to the cache when `-Xshareclasses:groupAccess` options is used + +# Explicity create a class cache layer for this image layer here rather than allowing +# `server start` to do it, which will lead to problems because multiple JVMs will be started. +java $CREATE_LAYER -Xscmx$SCC_SIZE -version + +if [ $TRIM_SCC == yes ] +then + echo "Calculating SCC layer upper bound, starting with initial size $SCC_SIZE." + # Populate the newly created class cache layer. + /opt/ibm/wlp/bin/server start && /opt/ibm/wlp/bin/server stop + # Find out how full it is. + FULL=`( java $PRINT_LAYER_STATS || true ) 2>&1 | awk '/^Cache is [0-9.]*% .*full/ {print substr($3, 1, length($3)-1)}'` + echo "SCC layer is $FULL% full. Destroying layer." + # Destroy the layer once we know roughly how much space we need. + java $DESTROY_LAYER || true + # Remove the m suffix. + SCC_SIZE="${SCC_SIZE:0:-1}" + # Calculate the new size based on how full the layer was (rounded to nearest m). + SCC_SIZE=`awk "BEGIN {print int($SCC_SIZE * $FULL / 100.0 + 0.5)}"` + # Make sure size is >0. + [ $SCC_SIZE -eq 0 ] && SCC_SIZE=1 + # Add the m suffix back. + SCC_SIZE="${SCC_SIZE}m" + echo "Re-creating layer with size $SCC_SIZE." + # Recreate the layer with the new size. + java $CREATE_LAYER -Xscmx$SCC_SIZE -version +fi + +# Populate the newly created class cache layer. +# Server start/stop to populate the /output/workarea and make subsequent server starts faster. +for ((i=0; i<$ITERATIONS; i++)) +do + /opt/ibm/wlp/bin/server start && /opt/ibm/wlp/bin/server stop +done + +# restore umask +umask ${OLD_UMASK} + +rm -rf /output/messaging /logs/* $WLP_OUTPUT_DIR/.classCache && chmod -R g+rwx /output/workarea + +if [[ -d "/output/resources" ]] +then + chmod -R g+rwx /output/resources +fi + +# Tell the user how full the final layer is. +FULL=`( java $PRINT_LAYER_STATS || true ) 2>&1 | awk '/^Cache is [0-9.]*% .*full/ {print substr($3, 1, length($3)-1)}'` +echo "SCC layer is $FULL% full." diff --git a/ga/23.0.0.7/kernel/helpers/runtime/docker-server.sh b/ga/23.0.0.7/kernel/helpers/runtime/docker-server.sh new file mode 100755 index 000000000..77f7b4260 --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/runtime/docker-server.sh @@ -0,0 +1,159 @@ +#!/bin/bash +# (C) Copyright IBM Corporation 2020. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +function importKeyCert() { + local CERT_FOLDER="${TLS_DIR:-/etc/x509/certs}" + local CRT_FILE="tls.crt" + local KEY_FILE="tls.key" + local CA_FILE="ca.crt" + local PASSWORD=$(openssl rand -base64 32 2>/dev/null) + local TRUSTSTORE_PASSWORD=$(openssl rand -base64 32 2>/dev/null) + local TMP_CERT=ca-bundle-temp.crt + local -r CRT_DELIMITER="/-----BEGIN CERTIFICATE-----/" + local KUBE_SA_FOLDER="/var/run/secrets/kubernetes.io/serviceaccount" + local KEYSTORE_FILE="/output/resources/security/key.p12" + local TRUSTSTORE_FILE="/output/resources/security/trust.p12" + + # Import the private key and certificate into new keytore + if [ -f "${CERT_FOLDER}/${KEY_FILE}" ] && [ -f "${CERT_FOLDER}/${CRT_FILE}" ]; then + echo "Found mounted TLS certificates, generating keystore" + mkdir -p /output/resources/security + if [ -f "${CERT_FOLDER}/${CA_FILE}" ]; then + openssl pkcs12 -export \ + -name "defaultKeyStore" \ + -inkey "${CERT_FOLDER}/${KEY_FILE}" \ + -in "${CERT_FOLDER}/${CRT_FILE}" \ + -certfile "${CERT_FOLDER}/${CA_FILE}" \ + -out "${KEYSTORE_FILE}" \ + -password pass:"${PASSWORD}" >&/dev/null + else + openssl pkcs12 -export \ + -name "defaultKeyStore" \ + -inkey "${CERT_FOLDER}/${KEY_FILE}" \ + -in "${CERT_FOLDER}/${CRT_FILE}" \ + -out "${KEYSTORE_FILE}" \ + -password pass:"${PASSWORD}" >&/dev/null + fi + + # Since we are creating new keystore, always write new password to a file + sed "s|REPLACE|$PASSWORD|g" $SNIPPETS_SOURCE/keystore.xml > $SNIPPETS_TARGET_DEFAULTS/keystore.xml + + # Add mounted CA to the truststore + if [ -f "${CERT_FOLDER}/${CA_FILE}" ]; then + echo "Found mounted TLS CA certificate, adding to truststore" + keytool -import -storetype pkcs12 -noprompt -keystore "${TRUSTSTORE_FILE}" -file "${CERT_FOLDER}/${CA_FILE}" \ + -storepass "${TRUSTSTORE_PASSWORD}" -alias "service-ca" >&/dev/null + fi + fi + + # Add kubernetes CA certificates to the truststore + # CA bundles need to be split and added as individual certificates + if [ "$SEC_IMPORT_K8S_CERTS" = "true" ] && [ -d "${KUBE_SA_FOLDER}" ]; then + mkdir /tmp/certs + pushd /tmp/certs >&/dev/null + cat ${KUBE_SA_FOLDER}/*.crt >${TMP_CERT} + csplit -s -z -f crt- "${TMP_CERT}" "${CRT_DELIMITER}" '{*}' + for CERT_FILE in crt-*; do + keytool -import -storetype pkcs12 -noprompt -keystore "${TRUSTSTORE_FILE}" -file "${CERT_FILE}" \ + -storepass "${TRUSTSTORE_PASSWORD}" -alias "service-sa-${CERT_FILE}" >&/dev/null + done + popd >&/dev/null + rm -rf /tmp/certs + fi + + # Add the keystore password to server configuration + if [ ! -e $keystorePath ]; then + sed "s|REPLACE|$PASSWORD|g" $SNIPPETS_SOURCE/keystore.xml > $SNIPPETS_TARGET_DEFAULTS/keystore.xml + fi + if [ -e $TRUSTSTORE_FILE ]; then + sed "s|PWD_TRUST|$TRUSTSTORE_PASSWORD|g" $SNIPPETS_SOURCE/truststore.xml > $SNIPPETS_TARGET_OVERRIDES/truststore.xml + elif [ ! -z $SEC_TLS_TRUSTDEFAULTCERTS ]; then + cp $SNIPPETS_SOURCE/trustDefault.xml $SNIPPETS_TARGET_OVERRIDES/trustDefault.xml + fi +} + +case "${LICENSE,,}" in + "accept" ) # Suppress license message in logs + grep -s -F "com.ibm.ws.logging.hideMessage" /config/bootstrap.properties \ + && sed -i 's/^\(com.ibm.ws.logging.hideMessage=.*$\)/\1,CWWKE0100I/' /config/bootstrap.properties \ + || echo "com.ibm.ws.logging.hideMessage=CWWKE0100I" >> /config/bootstrap.properties + ;; + "view" ) # Display license file + cat /opt/ibm/wlp/lafiles/LI_${LANG:-en} + exit 1 + ;; + "" ) # Continue, displaying license message in logs + true + ;; + *) # License not accepted + echo -e "Set environment variable LICENSE=accept to indicate acceptance of license terms and conditions.\n\nLicense agreements and information can be viewed by running this image with the environment variable LICENSE=view. You can also set the LANG environment variable to view the license in a different language." + exit 1 + ;; +esac + +SNIPPETS_SOURCE=/opt/ibm/helpers/build/configuration_snippets +SNIPPETS_TARGET_DEFAULTS=/config/configDropins/defaults +SNIPPETS_TARGET_OVERRIDES=/config/configDropins/overrides + +keystorePath="$SNIPPETS_TARGET_DEFAULTS/keystore.xml" + +importKeyCert + +# Infinispan Session Caching +if [[ -n "$INFINISPAN_SERVICE_NAME" ]]; then + echo "INFINISPAN_SERVICE_NAME(original): ${INFINISPAN_SERVICE_NAME}" + INFINISPAN_SERVICE_NAME=$(echo ${INFINISPAN_SERVICE_NAME} | sed 's/-/_/g' | sed 's/./\U&/g') + echo "INFINISPAN_SERVICE_NAME(normalized): ${INFINISPAN_SERVICE_NAME}" + + if [[ -z "$INFINISPAN_HOST" ]]; then + eval INFINISPAN_HOST=\$${INFINISPAN_SERVICE_NAME}_SERVICE_HOST + export INFINISPAN_HOST + fi + echo "INFINISPAN_HOST: ${INFINISPAN_HOST}" + + if [[ -z "$INFINISPAN_PORT" ]]; then + eval INFINISPAN_PORT=\$${INFINISPAN_SERVICE_NAME}_SERVICE_PORT + export INFINISPAN_PORT + fi + echo "INFINISPAN_PORT: ${INFINISPAN_PORT:=11222}" + + if [[ -z "$INFINISPAN_USER" ]]; then + export INFINISPAN_USER=$(cat ${LIBERTY_INFINISPAN_SECRET_DIR:=/platform/bindings/infinispan/secret}/identities.yaml | grep -m 1 username | sed 's/username://' | sed 's/[[:space:]]*//g' | sed 's/^-//') + fi + echo "INFINISPAN_USER: ${INFINISPAN_USER:=developer}" + + if [[ -z "$INFINISPAN_PASS" ]]; then + export INFINISPAN_PASS=$(cat ${LIBERTY_INFINISPAN_SECRET_DIR:=/platform/bindings/infinispan/secret}/identities.yaml | grep -m 1 password | sed 's/password://' | sed 's/[[:space:]]*//g') + fi + echo "INFINISPAN_PASS: ${INFINISPAN_PASS}" +fi + + +# Pass on to the real server run +if [ -d "/output/workarea/checkpoint/image" ]; then + # A checkpoint image found; exec dumb-init for signal handling. + # Use of dumb-init for PID 1 is required for signal handling because + # the restored server process cannot be PID 1. + exec dumb-init --rewrite 15:2 -- /opt/ibm/helpers/runtime/restore-server.sh "$@" +elif [[ ! -z "$WLP_CHECKPOINT" ]]; then + # Unset WLP_CHECKPOINT so it is not set in the final image after checkpoint. + TMP_CHECKPOINT=$WLP_CHECKPOINT + unset WLP_CHECKPOINT + # A checkpoint action has been requested; run the checkpoint.sh script. + checkpoint.sh "$TMP_CHECKPOINT" +else + # The default is to just exec the supplied CMD + exec "$@" +fi diff --git a/ga/23.0.0.7/kernel/helpers/runtime/restore-server.sh b/ga/23.0.0.7/kernel/helpers/runtime/restore-server.sh new file mode 100755 index 000000000..cdcd84894 --- /dev/null +++ b/ga/23.0.0.7/kernel/helpers/runtime/restore-server.sh @@ -0,0 +1,6 @@ +#!/bin/bash + +# For restore use a copy of criu that does not have sys_ptrace +export CRIU_RESTORE_PATH=/opt/criu/criu +exec "$@" + diff --git a/ga/23.0.0.7/oidcProvider/Dockerfile b/ga/23.0.0.7/oidcProvider/Dockerfile new file mode 100644 index 000000000..5d13b61fb --- /dev/null +++ b/ga/23.0.0.7/oidcProvider/Dockerfile @@ -0,0 +1,32 @@ +# (C) Copyright IBM Corporation 2019. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +FROM websphere-liberty:kernel + +ARG REPOSITORIES_PROPERTIES="" + +RUN if [ ! -z $REPOSITORIES_PROPERTIES ]; then mkdir /opt/ibm/wlp/etc/ \ + && echo $REPOSITORIES_PROPERTIES > /opt/ibm/wlp/etc/repositories.properties; fi \ + && installUtility install --acceptLicense \ + appSecurity-2.0 ldapRegistry-3.0 \ + localConnector-1.0 \ + samlWeb-2.0 \ + openidConnectServer-1.0 \ + socialLogin-1.0 \ + openidConnectClient-1.0 \ + && if [ ! -z $REPOSITORIES_PROPERTIES ]; then rm /opt/ibm/wlp/etc/repositories.properties; fi \ + && rm -rf /output/workarea /output/logs \ + && chmod -R g+rwx /opt/ibm/wlp/output/* + +COPY --chown=1001:0 server.xml /config/ diff --git a/ga/23.0.0.7/oidcProvider/Dockerfile.java11 b/ga/23.0.0.7/oidcProvider/Dockerfile.java11 new file mode 100644 index 000000000..20a2f5320 --- /dev/null +++ b/ga/23.0.0.7/oidcProvider/Dockerfile.java11 @@ -0,0 +1,32 @@ +# (C) Copyright IBM Corporation 2019. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +FROM websphere-liberty:kernel-java11 + +ARG REPOSITORIES_PROPERTIES="" + +RUN if [ ! -z $REPOSITORIES_PROPERTIES ]; then mkdir /opt/ibm/wlp/etc/ \ + && echo $REPOSITORIES_PROPERTIES > /opt/ibm/wlp/etc/repositories.properties; fi \ + && installUtility install --acceptLicense \ + appSecurity-2.0 ldapRegistry-3.0 \ + localConnector-1.0 \ + samlWeb-2.0 \ + openidConnectServer-1.0 \ + socialLogin-1.0 \ + openidConnectClient-1.0 \ + && if [ ! -z $REPOSITORIES_PROPERTIES ]; then rm /opt/ibm/wlp/etc/repositories.properties; fi \ + && rm -rf /output/workarea /output/logs \ + && chmod -R g+rwx /opt/ibm/wlp/output/* + +COPY --chown=1001:0 server.xml /config/ diff --git a/ga/23.0.0.7/oidcProvider/README.md b/ga/23.0.0.7/oidcProvider/README.md new file mode 100644 index 000000000..52d2c87f5 --- /dev/null +++ b/ga/23.0.0.7/oidcProvider/README.md @@ -0,0 +1,7 @@ +# WebSphere Application Server Developer Edition Liberty image + +The [Dockerfile](Dockerfile) in this directory is used to build the `websphere-liberty:oidcProvider` image on [Docker Hub](https://registry.hub.docker.com/_/websphere-liberty/). + +# Usage + +TODO diff --git a/ga/23.0.0.7/oidcProvider/server.xml b/ga/23.0.0.7/oidcProvider/server.xml new file mode 100644 index 000000000..5b94ec95b --- /dev/null +++ b/ga/23.0.0.7/oidcProvider/server.xml @@ -0,0 +1,143 @@ + + + + + openidConnectServer-1.0 + ldapRegistry-3.0 + + + + + + + + + + + + + + + + + + + + + + + + + + + regexp:https://${env.OIDCP_INGRESS_HOST_REGEX}:3!d!d!d!d/oidcclient/redirect/rp + https://${env.OIDCP_INGRESS_HOST}/oidcclient/redirect/rp + + + + ${env.OIDCP_CUSTOM_CLIENT_REDIRECT} + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/ga/latest/kernel/Dockerfile.ubi.ibmjava8 b/ga/latest/kernel/Dockerfile.ubi.ibmjava8 index 0b4a832e9..0218db758 100644 --- a/ga/latest/kernel/Dockerfile.ubi.ibmjava8 +++ b/ga/latest/kernel/Dockerfile.ubi.ibmjava8 @@ -19,7 +19,7 @@ USER root ARG VERBOSE=false # Install WebSphere Liberty -ARG LIBERTY_VERSION=23.0.0.6 +ARG LIBERTY_VERSION=23.0.0.7 ARG LIBERTY_URL ARG DOWNLOAD_OPTIONS="" @@ -45,8 +45,8 @@ USER root ARG VERBOSE=false ARG OPENJ9_SCC=true -ARG LIBERTY_VERSION=23.0.0.6 -ARG LIBERTY_BUILD_LABEL=cl230620230612-1100 +ARG LIBERTY_VERSION=23.0.0.7 +ARG LIBERTY_BUILD_LABEL=cl230720230710-1201 LABEL org.opencontainers.image.authors="Leo Christy Jesuraj, Thomas Watson, Wendy Raschke, Michal Broz" \ org.opencontainers.image.vendor="IBM" \ diff --git a/ga/latest/kernel/Dockerfile.ubi.openjdk11 b/ga/latest/kernel/Dockerfile.ubi.openjdk11 index 81feb104c..b5882d924 100644 --- a/ga/latest/kernel/Dockerfile.ubi.openjdk11 +++ b/ga/latest/kernel/Dockerfile.ubi.openjdk11 @@ -19,7 +19,7 @@ USER root ARG VERBOSE=false # Install WebSphere Liberty -ARG LIBERTY_VERSION=23.0.0.6 +ARG LIBERTY_VERSION=23.0.0.7 ARG LIBERTY_URL ARG DOWNLOAD_OPTIONS="" @@ -45,8 +45,8 @@ USER root ARG VERBOSE=false ARG OPENJ9_SCC=true -ARG LIBERTY_VERSION=23.0.0.6 -ARG LIBERTY_BUILD_LABEL=cl230620230612-1100 +ARG LIBERTY_VERSION=23.0.0.7 +ARG LIBERTY_BUILD_LABEL=cl230720230710-1201 LABEL org.opencontainers.image.authors="Leo Christy Jesuraj, Thomas Watson, Wendy Raschke, Michal Broz" \ org.opencontainers.image.vendor="IBM" \ diff --git a/ga/latest/kernel/Dockerfile.ubi.openjdk17 b/ga/latest/kernel/Dockerfile.ubi.openjdk17 index be47a9aa2..569932d85 100644 --- a/ga/latest/kernel/Dockerfile.ubi.openjdk17 +++ b/ga/latest/kernel/Dockerfile.ubi.openjdk17 @@ -19,7 +19,7 @@ USER root ARG VERBOSE=false # Install WebSphere Liberty -ARG LIBERTY_VERSION=23.0.0.6 +ARG LIBERTY_VERSION=23.0.0.7 ARG LIBERTY_URL ARG DOWNLOAD_OPTIONS="" @@ -45,8 +45,8 @@ USER root ARG VERBOSE=false ARG OPENJ9_SCC=true -ARG LIBERTY_VERSION=23.0.0.6 -ARG LIBERTY_BUILD_LABEL=cl230620230612-1100 +ARG LIBERTY_VERSION=23.0.0.7 +ARG LIBERTY_BUILD_LABEL=cl230720230710-1201 LABEL org.opencontainers.image.authors="Leo Christy Jesuraj, Thomas Watson, Wendy Raschke, Michal Broz" \ org.opencontainers.image.vendor="IBM" \ diff --git a/ga/latest/kernel/Dockerfile.ubi.openjdk8 b/ga/latest/kernel/Dockerfile.ubi.openjdk8 index ef3b64d27..90927869d 100644 --- a/ga/latest/kernel/Dockerfile.ubi.openjdk8 +++ b/ga/latest/kernel/Dockerfile.ubi.openjdk8 @@ -19,7 +19,7 @@ USER root ARG VERBOSE=false # Install WebSphere Liberty -ARG LIBERTY_VERSION=23.0.0.6 +ARG LIBERTY_VERSION=23.0.0.7 ARG LIBERTY_URL ARG DOWNLOAD_OPTIONS="" @@ -45,8 +45,8 @@ USER root ARG VERBOSE=false ARG OPENJ9_SCC=true -ARG LIBERTY_VERSION=23.0.0.6 -ARG LIBERTY_BUILD_LABEL=cl230620230612-1100 +ARG LIBERTY_VERSION=23.0.0.7 +ARG LIBERTY_BUILD_LABEL=cl230720230710-1201 LABEL org.opencontainers.image.authors="Leo Christy Jesuraj, Thomas Watson, Wendy Raschke, Michal Broz" \ org.opencontainers.image.vendor="IBM" \ diff --git a/ga/latest/kernel/Dockerfile.ubuntu.ibmjava8 b/ga/latest/kernel/Dockerfile.ubuntu.ibmjava8 index 18c859d77..7585c56a1 100644 --- a/ga/latest/kernel/Dockerfile.ubuntu.ibmjava8 +++ b/ga/latest/kernel/Dockerfile.ubuntu.ibmjava8 @@ -19,8 +19,8 @@ USER root ARG VERBOSE=false ARG OPENJ9_SCC=true -ARG LIBERTY_VERSION=23.0.0.6 -ARG LIBERTY_BUILD_LABEL=cl230620230612-1100 +ARG LIBERTY_VERSION=23.0.0.7 +ARG LIBERTY_BUILD_LABEL=cl230720230710-1201 LABEL org.opencontainers.image.authors="Leo Christy Jesuraj, Thomas Watson, Wendy Raschke, Michal Broz" \ org.opencontainers.image.vendor="IBM" \ @@ -154,3 +154,4 @@ EXPOSE 9080 9443 ENTRYPOINT ["/opt/ibm/helpers/runtime/docker-server.sh"] CMD ["/opt/ibm/wlp/bin/server", "run", "defaultServer"] + diff --git a/ga/latest/kernel/Dockerfile.ubuntu.openjdk11 b/ga/latest/kernel/Dockerfile.ubuntu.openjdk11 index 5869604de..81df829b9 100644 --- a/ga/latest/kernel/Dockerfile.ubuntu.openjdk11 +++ b/ga/latest/kernel/Dockerfile.ubuntu.openjdk11 @@ -19,8 +19,8 @@ USER root ARG VERBOSE=false ARG OPENJ9_SCC=true -ARG LIBERTY_VERSION=23.0.0.6 -ARG LIBERTY_BUILD_LABEL=cl230620230612-1100 +ARG LIBERTY_VERSION=23.0.0.7 +ARG LIBERTY_BUILD_LABEL=cl230720230710-1201 LABEL org.opencontainers.image.authors="Leo Christy Jesuraj, Thomas Watson, Wendy Raschke, Michal Broz" \ org.opencontainers.image.vendor="IBM" \ @@ -149,3 +149,4 @@ EXPOSE 9080 9443 ENTRYPOINT ["/opt/ibm/helpers/runtime/docker-server.sh"] CMD ["/opt/ibm/wlp/bin/server", "run", "defaultServer"] + diff --git a/ga/latest/kernel/Dockerfile.ubuntu.openjdk17 b/ga/latest/kernel/Dockerfile.ubuntu.openjdk17 index c266368f0..af3d57d3e 100644 --- a/ga/latest/kernel/Dockerfile.ubuntu.openjdk17 +++ b/ga/latest/kernel/Dockerfile.ubuntu.openjdk17 @@ -19,8 +19,8 @@ USER root ARG VERBOSE=false ARG OPENJ9_SCC=true -ARG LIBERTY_VERSION=23.0.0.6 -ARG LIBERTY_BUILD_LABEL=cl230620230612-1100 +ARG LIBERTY_VERSION=23.0.0.7 +ARG LIBERTY_BUILD_LABEL=cl230720230710-1201 LABEL org.opencontainers.image.authors="Leo Christy Jesuraj, Thomas Watson, Wendy Raschke, Michal Broz" \ org.opencontainers.image.vendor="IBM" \ @@ -149,3 +149,4 @@ EXPOSE 9080 9443 ENTRYPOINT ["/opt/ibm/helpers/runtime/docker-server.sh"] CMD ["/opt/ibm/wlp/bin/server", "run", "defaultServer"] + From ed85559cb27d5a065f4a512c8b204e5620c6d0fc Mon Sep 17 00:00:00 2001 From: Wendy Raschke Date: Wed, 12 Jul 2023 14:35:11 -0700 Subject: [PATCH 11/19] Image names need correction --- ga/23.0.0.7/full/Dockerfile.ubi.ibmjava8 | 4 ++-- ga/23.0.0.7/full/Dockerfile.ubi.openjdk11 | 4 ++-- ga/23.0.0.7/full/Dockerfile.ubi.openjdk17 | 4 ++-- ga/23.0.0.7/full/Dockerfile.ubi.openjdk8 | 4 ++-- ga/23.0.0.7/full/Dockerfile.ubuntu.ibmjava8 | 4 ++-- ga/23.0.0.7/full/Dockerfile.ubuntu.openjdk11 | 4 ++-- ga/23.0.0.7/full/Dockerfile.ubuntu.openjdk17 | 4 ++-- 7 files changed, 14 insertions(+), 14 deletions(-) diff --git a/ga/23.0.0.7/full/Dockerfile.ubi.ibmjava8 b/ga/23.0.0.7/full/Dockerfile.ubi.ibmjava8 index 2a2aef089..7459b92eb 100644 --- a/ga/23.0.0.7/full/Dockerfile.ubi.ibmjava8 +++ b/ga/23.0.0.7/full/Dockerfile.ubi.ibmjava8 @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:kernel-java8-ibmjava-ubi +ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:23.0.0.7-kernel-java8-ibmjava-ubi FROM $PARENT_IMAGE AS installBundle USER root @@ -38,7 +38,7 @@ RUN set -eux; \ rm -rf /output/workarea /output/logs; \ find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw; -ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:kernel-java8-ibmjava-ubi +ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:23.0.0.7-kernel-java8-ibmjava-ubi FROM $PARENT_IMAGE ARG VERBOSE=false diff --git a/ga/23.0.0.7/full/Dockerfile.ubi.openjdk11 b/ga/23.0.0.7/full/Dockerfile.ubi.openjdk11 index 79f2900b0..7ea47011f 100644 --- a/ga/23.0.0.7/full/Dockerfile.ubi.openjdk11 +++ b/ga/23.0.0.7/full/Dockerfile.ubi.openjdk11 @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:kernel-java11-openj9-ubi +ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:23.0.0.7-kernel-java11-openj9-ubi FROM $PARENT_IMAGE AS installBundle USER root @@ -38,7 +38,7 @@ RUN set -eux; \ rm -rf /output/workarea /output/logs; \ find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw; -ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:kernel-java11-openj9-ubi +ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:23.0.0.7-kernel-java11-openj9-ubi FROM $PARENT_IMAGE ARG VERBOSE=false diff --git a/ga/23.0.0.7/full/Dockerfile.ubi.openjdk17 b/ga/23.0.0.7/full/Dockerfile.ubi.openjdk17 index dc91e1978..d7911fdba 100644 --- a/ga/23.0.0.7/full/Dockerfile.ubi.openjdk17 +++ b/ga/23.0.0.7/full/Dockerfile.ubi.openjdk17 @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:kernel-java17-openj9-ubi +ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:23.0.0.7-kernel-java17-openj9-ubi FROM $PARENT_IMAGE AS installBundle USER root @@ -38,7 +38,7 @@ RUN set -eux; \ rm -rf /output/workarea /output/logs; \ find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw; -ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:kernel-java17-openj9-ubi +ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:23.0.0.7-kernel-java17-openj9-ubi FROM $PARENT_IMAGE ARG VERBOSE=false diff --git a/ga/23.0.0.7/full/Dockerfile.ubi.openjdk8 b/ga/23.0.0.7/full/Dockerfile.ubi.openjdk8 index 1d700de48..420ecdb24 100644 --- a/ga/23.0.0.7/full/Dockerfile.ubi.openjdk8 +++ b/ga/23.0.0.7/full/Dockerfile.ubi.openjdk8 @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:kernel-java8-openj9-ubi +ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:23.0.0.7-kernel-java8-openj9-ubi FROM $PARENT_IMAGE AS installBundle USER root @@ -38,7 +38,7 @@ RUN set -eux; \ rm -rf /output/workarea /output/logs; \ find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw; -ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:kernel-java8-openj9-ubi +ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:23.0.0.7-kernel-java8-openj9-ubi FROM $PARENT_IMAGE ARG VERBOSE=false diff --git a/ga/23.0.0.7/full/Dockerfile.ubuntu.ibmjava8 b/ga/23.0.0.7/full/Dockerfile.ubuntu.ibmjava8 index 395a6922a..a200f948e 100644 --- a/ga/23.0.0.7/full/Dockerfile.ubuntu.ibmjava8 +++ b/ga/23.0.0.7/full/Dockerfile.ubuntu.ibmjava8 @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM websphere-liberty:kernel AS installBundle +FROM websphere-liberty:23.0.0.7-kernel-java8-ibmjava AS installBundle ARG VERBOSE=false ARG REPOSITORIES_PROPERTIES="" @@ -34,7 +34,7 @@ RUN set -eux; \ rm -rf /output/workarea /output/logs; \ find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw; -FROM websphere-liberty:kernel +FROM websphere-liberty:23.0.0.7-kernel-java8-ibmjava ARG VERBOSE=false # Copy the runtime diff --git a/ga/23.0.0.7/full/Dockerfile.ubuntu.openjdk11 b/ga/23.0.0.7/full/Dockerfile.ubuntu.openjdk11 index 02fd841cd..6695e83f2 100644 --- a/ga/23.0.0.7/full/Dockerfile.ubuntu.openjdk11 +++ b/ga/23.0.0.7/full/Dockerfile.ubuntu.openjdk11 @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM websphere-liberty:kernel-java11-openj9 AS installBundle +FROM websphere-liberty:23.0.0.7-kernel-java11-openj9 AS installBundle USER root @@ -37,7 +37,7 @@ RUN set -eux; \ rm -rf /output/workarea /output/logs; \ find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw; -FROM websphere-liberty:kernel-java11-openj9 +FROM websphere-liberty:23.0.0.7-kernel-java11-openj9 ARG VERBOSE=false # Copy the runtime diff --git a/ga/23.0.0.7/full/Dockerfile.ubuntu.openjdk17 b/ga/23.0.0.7/full/Dockerfile.ubuntu.openjdk17 index 1241066c1..4b5e98a02 100644 --- a/ga/23.0.0.7/full/Dockerfile.ubuntu.openjdk17 +++ b/ga/23.0.0.7/full/Dockerfile.ubuntu.openjdk17 @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM websphere-liberty:kernel-java17-openj9 AS installBundle +FROM websphere-liberty:23.0.0.7-kernel-java17-openj9 AS installBundle USER root @@ -37,7 +37,7 @@ RUN set -eux; \ rm -rf /output/workarea /output/logs; \ find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw; -FROM websphere-liberty:kernel-java17-openj9 +FROM websphere-liberty:23.0.0.7-kernel-java17-openj9 ARG VERBOSE=false # Copy the runtime From d561846c2e4147ec0235ff1cba87862971d2892f Mon Sep 17 00:00:00 2001 From: Wendy Raschke Date: Mon, 17 Jul 2023 11:06:15 -0700 Subject: [PATCH 12/19] Update Travis YML file for record keeping --- .travis.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index 7983df682..d68cc6677 100644 --- a/.travis.yml +++ b/.travis.yml @@ -8,9 +8,9 @@ services: before_install: - sudo apt-get update env: - - RELEASE=../ga/22.0.0.12 - RELEASE=../ga/23.0.0.3 - - RELEASE=../ga/23.0.0.5 + - RELEASE=../ga/23.0.0.6 + - RELEASE=../ga/23.0.0.7 - RELEASE=../ga/latest script: From 843878566e01118b829be22b8043a50df8d8f645 Mon Sep 17 00:00:00 2001 From: Wendy Raschke Date: Tue, 18 Jul 2023 06:42:51 -0700 Subject: [PATCH 13/19] Required resources directory --- ga/23.0.0.7/full/resources/.gitkeep | 0 ga/23.0.0.7/kernel/resources/.gitkeep | 0 2 files changed, 0 insertions(+), 0 deletions(-) create mode 100644 ga/23.0.0.7/full/resources/.gitkeep create mode 100644 ga/23.0.0.7/kernel/resources/.gitkeep diff --git a/ga/23.0.0.7/full/resources/.gitkeep b/ga/23.0.0.7/full/resources/.gitkeep new file mode 100644 index 000000000..e69de29bb diff --git a/ga/23.0.0.7/kernel/resources/.gitkeep b/ga/23.0.0.7/kernel/resources/.gitkeep new file mode 100644 index 000000000..e69de29bb From 26fc7ebb0e2e7e6928c793adfc53e952cc1a9318 Mon Sep 17 00:00:00 2001 From: Wendy Raschke Date: Tue, 25 Jul 2023 08:54:41 -0700 Subject: [PATCH 14/19] 23.0.0.7 Ubuntu Dockerfiles must be single stage --- ga/23.0.0.7/full/Dockerfile.ubuntu.ibmjava8 | 21 ++----- ga/23.0.0.7/full/Dockerfile.ubuntu.openjdk11 | 21 ++----- ga/23.0.0.7/full/Dockerfile.ubuntu.openjdk17 | 21 ++----- ga/23.0.0.7/kernel/Dockerfile.ubuntu.ibmjava8 | 57 +++++++------------ .../kernel/Dockerfile.ubuntu.openjdk11 | 56 ++++++------------ .../kernel/Dockerfile.ubuntu.openjdk17 | 56 ++++++------------ 6 files changed, 68 insertions(+), 164 deletions(-) diff --git a/ga/23.0.0.7/full/Dockerfile.ubuntu.ibmjava8 b/ga/23.0.0.7/full/Dockerfile.ubuntu.ibmjava8 index a200f948e..735e362e9 100644 --- a/ga/23.0.0.7/full/Dockerfile.ubuntu.ibmjava8 +++ b/ga/23.0.0.7/full/Dockerfile.ubuntu.ibmjava8 @@ -12,38 +12,27 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM websphere-liberty:23.0.0.7-kernel-java8-ibmjava AS installBundle +FROM websphere-liberty:23.0.0.7-kernel-java8-ibmjava + ARG VERBOSE=false ARG REPOSITORIES_PROPERTIES="" -# If there is a local copy of the repository use that instead -COPY resources/ /tmp/ - # Install the base bundle RUN set -eux; \ if [ ! -z "$REPOSITORIES_PROPERTIES" ]; then \ mkdir /opt/ibm/wlp/etc/; \ echo "$REPOSITORIES_PROPERTIES" > /opt/ibm/wlp/etc/repositories.properties; \ - installUtility install --acceptLicense baseBundle; \ + fi; \ + installUtility install --acceptLicense baseBundle; \ + if [ ! -z "$REPOSITORIES_PROPERTIES" ]; then \ rm /opt/ibm/wlp/etc/repositories.properties; \ - elif [ -f /tmp/wlpRepo.zip ]; then \ - installUtility install --acceptLicense baseBundle --from=/tmp/wlpRepo.zip; \ - else \ - installUtility install --acceptLicense baseBundle; \ fi; \ rm -rf /output/workarea /output/logs; \ find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw; -FROM websphere-liberty:23.0.0.7-kernel-java8-ibmjava -ARG VERBOSE=false - -# Copy the runtime -COPY --from=installBundle /opt/ibm/wlp /opt/ibm/wlp - COPY --chown=1001:0 server.xml /config/ # Create a new SCC layer RUN if [ "$OPENJ9_SCC" = "true" ]; then populate_scc.sh; fi \ && rm -rf /output/messaging /output/resources/security /logs/* $WLP_OUTPUT_DIR/.classCache \ && find /opt/ibm/wlp/output ! -path "*.classCache*" ! -perm -g=rwx -print0 | xargs -0 -r chmod g+rwx - diff --git a/ga/23.0.0.7/full/Dockerfile.ubuntu.openjdk11 b/ga/23.0.0.7/full/Dockerfile.ubuntu.openjdk11 index 6695e83f2..814a5f02d 100644 --- a/ga/23.0.0.7/full/Dockerfile.ubuntu.openjdk11 +++ b/ga/23.0.0.7/full/Dockerfile.ubuntu.openjdk11 @@ -12,37 +12,24 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM websphere-liberty:23.0.0.7-kernel-java11-openj9 AS installBundle - -USER root +FROM websphere-liberty:23.0.0.7-kernel-java11-openj9 ARG VERBOSE=false ARG REPOSITORIES_PROPERTIES="" -# If there is a local copy of the repository use that instead -COPY resources/ /tmp/ - # Install the base bundle RUN set -eux; \ if [ ! -z "$REPOSITORIES_PROPERTIES" ]; then \ mkdir /opt/ibm/wlp/etc/; \ echo "$REPOSITORIES_PROPERTIES" > /opt/ibm/wlp/etc/repositories.properties; \ - installUtility install --acceptLicense baseBundle; \ + fi; \ + installUtility install --acceptLicense baseBundle; \ + if [ ! -z "$REPOSITORIES_PROPERTIES" ]; then \ rm /opt/ibm/wlp/etc/repositories.properties; \ - elif [ -f /tmp/wlpRepo.zip ]; then \ - installUtility install --acceptLicense baseBundle --from=/tmp/wlpRepo.zip; \ - else \ - installUtility install --acceptLicense baseBundle; \ fi; \ rm -rf /output/workarea /output/logs; \ find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw; -FROM websphere-liberty:23.0.0.7-kernel-java11-openj9 -ARG VERBOSE=false - -# Copy the runtime -COPY --from=installBundle /opt/ibm/wlp /opt/ibm/wlp - COPY --chown=1001:0 server.xml /config/ # Create a new SCC layer diff --git a/ga/23.0.0.7/full/Dockerfile.ubuntu.openjdk17 b/ga/23.0.0.7/full/Dockerfile.ubuntu.openjdk17 index 4b5e98a02..436a388f2 100644 --- a/ga/23.0.0.7/full/Dockerfile.ubuntu.openjdk17 +++ b/ga/23.0.0.7/full/Dockerfile.ubuntu.openjdk17 @@ -12,37 +12,24 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM websphere-liberty:23.0.0.7-kernel-java17-openj9 AS installBundle - -USER root +FROM websphere-liberty:23.0.0.7-kernel-java17-openj9 ARG VERBOSE=false ARG REPOSITORIES_PROPERTIES="" -# If there is a local copy of the repository use that instead -COPY resources/ /tmp/ - # Install the base bundle RUN set -eux; \ if [ ! -z "$REPOSITORIES_PROPERTIES" ]; then \ mkdir /opt/ibm/wlp/etc/; \ echo "$REPOSITORIES_PROPERTIES" > /opt/ibm/wlp/etc/repositories.properties; \ - installUtility install --acceptLicense baseBundle; \ + fi; \ + installUtility install --acceptLicense baseBundle; \ + if [ ! -z "$REPOSITORIES_PROPERTIES" ]; then \ rm /opt/ibm/wlp/etc/repositories.properties; \ - elif [ -f /tmp/wlpRepo.zip ]; then \ - installUtility install --acceptLicense baseBundle --from=/tmp/wlpRepo.zip; \ - else \ - installUtility install --acceptLicense baseBundle; \ fi; \ rm -rf /output/workarea /output/logs; \ find /opt/ibm/wlp ! -perm -g=rw -print0 | xargs -r -0 chmod g+rw; -FROM websphere-liberty:23.0.0.7-kernel-java17-openj9 -ARG VERBOSE=false - -# Copy the runtime -COPY --from=installBundle /opt/ibm/wlp /opt/ibm/wlp - COPY --chown=1001:0 server.xml /config/ # Create a new SCC layer diff --git a/ga/23.0.0.7/kernel/Dockerfile.ubuntu.ibmjava8 b/ga/23.0.0.7/kernel/Dockerfile.ubuntu.ibmjava8 index 796d40ac0..0342ad8bb 100644 --- a/ga/23.0.0.7/kernel/Dockerfile.ubuntu.ibmjava8 +++ b/ga/23.0.0.7/kernel/Dockerfile.ubuntu.ibmjava8 @@ -12,32 +12,6 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM ibmjava:8-jre AS getRuntime - -USER root - -ARG VERBOSE=false - -# Install WebSphere Liberty -ARG LIBERTY_VERSION=23.0.0.7 -ARG LIBERTY_URL -ARG DOWNLOAD_OPTIONS="" - -# If there is a local copy of the image use that instead -COPY resources/ /tmp/ - -RUN apt-get update \ - && apt-get install -y --no-install-recommends unzip wget openssl \ - && rm -rf /var/lib/apt/lists/* \ - && mkdir -p /licenses/ \ - && useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ - && LIBERTY_URL=${LIBERTY_URL:-$(wget -q -O - https://public.dhe.ibm.com/ibmdl/export/pub/software/websphere/wasdev/downloads/wlp/index.yml | grep -E "^\s*kernel:.*${LIBERTY_VERSION}\.zip" | sed -n 's/\s*kernel:\s//p' | tr -d '\r' )} \ - && if [ ! -f /tmp/wlp.zip ]; then wget $DOWNLOAD_OPTIONS $LIBERTY_URL -U UA-IBM-WebSphere-Liberty-Docker -O /tmp/wlp.zip; fi \ - && unzip -q /tmp/wlp.zip -d /opt/ibm \ - && chown -R 1001:0 /opt/ibm/wlp \ - && chmod -R g+rw /opt/ibm/wlp \ - && cp -a /opt/ibm/wlp/lafiles/. /licenses/ - FROM ibmjava:8-jre USER root @@ -95,20 +69,27 @@ RUN set -eux; \ curl -LfsSo /usr/bin/dumb-init ${DUMB_INIT_URL}; \ echo "${DUMB_INIT_SHA256} */usr/bin/dumb-init" | sha256sum -c -; \ chmod +x /usr/bin/dumb-init; \ - apt-get purge --auto-remove -y wget; \ + apt-get purge --auto-remove -y curl; \ rm -rf /var/lib/apt/lists/*; -# Add default user 1001 and create wlp with right user/permissions before copying -RUN useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ - && mkdir -p /opt/ibm/wlp \ - && chown -R 1001:0 /opt/ibm/wlp \ - && chmod -R g+rw /opt/ibm/wlp - -# Copy the runtime and licenses -COPY --from=getRuntime --chown=1001:0 /opt/ibm/wlp /opt/ibm/wlp -COPY --from=getRuntime /licenses /licenses +# Install WebSphere Liberty +ARG LIBERTY_URL +ARG DOWNLOAD_OPTIONS="" -RUN apt-get install -y --no-install-recommends openssl \ +RUN apt-get update \ + && apt-get install -y --no-install-recommends unzip wget openssl \ + && rm -rf /var/lib/apt/lists/* \ + && mkdir -p /licenses/ \ + && useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ + && LIBERTY_URL=${LIBERTY_URL:-$(wget -q -O - https://public.dhe.ibm.com/ibmdl/export/pub/software/websphere/wasdev/downloads/wlp/index.yml | grep -E "^\s*kernel:.*${LIBERTY_VERSION}\.zip" | sed -n 's/\s*kernel:\s//p' | tr -d '\r' )} \ + && wget $DOWNLOAD_OPTIONS $LIBERTY_URL -U UA-IBM-WebSphere-Liberty-Docker -O /tmp/wlp.zip \ + && unzip -q /tmp/wlp.zip -d /opt/ibm \ + && rm /tmp/wlp.zip \ + && chown -R 1001:0 /opt/ibm/wlp \ + && chmod -R g+rw /opt/ibm/wlp \ + && cp -a /opt/ibm/wlp/lafiles/. /licenses/ \ + && apt-get purge --auto-remove -y unzip \ + && apt-get purge --auto-remove -y wget \ && rm -rf /var/lib/apt/lists/* # Set Path Shortcuts @@ -135,7 +116,7 @@ RUN mkdir /logs \ && rm -rf /output \ && ln -s $WLP_OUTPUT_DIR/defaultServer /output \ && ln -s /opt/ibm/wlp/usr/servers/defaultServer /config \ - && ln -s /opt/ibm /liberty \ + && ln -s /opt/ibm/wlp /liberty \ && ln -s /opt/ibm/fixes /fixes \ && ln -s /opt/ibm/wlp/usr/shared/resources/lib.index.cache /lib.index.cache \ && mkdir -p /config/configDropins/defaults \ diff --git a/ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk11 b/ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk11 index 808d8dac3..727d9ad06 100644 --- a/ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk11 +++ b/ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk11 @@ -12,33 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM ibm-semeru-runtimes:open-11-jre-focal AS getRuntime - -USER root - -ARG VERBOSE=false - -# Install WebSphere Liberty -ARG LIBERTY_VERSION=23.0.0.7 -ARG LIBERTY_URL -ARG DOWNLOAD_OPTIONS="" - -# If there is a local copy of the image use that instead -COPY resources/ /tmp/ - -RUN apt-get update \ - && apt-get install -y --no-install-recommends unzip wget openssl \ - && rm -rf /var/lib/apt/lists/* \ - && mkdir -p /licenses/ \ - && useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ - && LIBERTY_URL=${LIBERTY_URL:-$(wget -q -O - https://public.dhe.ibm.com/ibmdl/export/pub/software/websphere/wasdev/downloads/wlp/index.yml | grep -E "^\s*kernel:.*${LIBERTY_VERSION}\.zip" | sed -n 's/\s*kernel:\s//p' | tr -d '\r' )} \ - && if [ ! -f /tmp/wlp.zip ]; then wget $DOWNLOAD_OPTIONS $LIBERTY_URL -U UA-IBM-WebSphere-Liberty-Docker -O /tmp/wlp.zip; fi \ - && unzip -q /tmp/wlp.zip -d /opt/ibm \ - && chown -R 1001:0 /opt/ibm/wlp \ - && chmod -R g+rw /opt/ibm/wlp \ - && cp -a /opt/ibm/wlp/lafiles/. /licenses/ - -FROM ibm-semeru-runtimes:open-11-jre-focal +FROM ibm-semeru-runtimes:open-11-jre-jammy USER root @@ -94,17 +68,23 @@ RUN set -eux; \ echo "${DUMB_INIT_SHA256} */usr/bin/dumb-init" | sha256sum -c -; \ chmod +x /usr/bin/dumb-init; -# Add default user 1001 and create wlp with right user/permissions before copying -RUN useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ - && mkdir -p /opt/ibm/wlp \ +# Install WebSphere Liberty +ARG LIBERTY_URL +ARG DOWNLOAD_OPTIONS="" +RUN apt-get update \ + && apt-get install -y --no-install-recommends unzip openssl wget \ + && rm -rf /var/lib/apt/lists/* \ + && mkdir -p /licenses/ \ + && useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ + && LIBERTY_URL=${LIBERTY_URL:-$(wget -q -O - https://public.dhe.ibm.com/ibmdl/export/pub/software/websphere/wasdev/downloads/wlp/index.yml | grep -E "^\s*kernel:.*${LIBERTY_VERSION}\.zip" | sed -n 's/\s*kernel:\s//p' | tr -d '\r' )} \ + && wget $DOWNLOAD_OPTIONS $LIBERTY_URL -U UA-IBM-WebSphere-Liberty-Docker -O /tmp/wlp.zip \ + && unzip -q /tmp/wlp.zip -d /opt/ibm \ + && rm /tmp/wlp.zip \ && chown -R 1001:0 /opt/ibm/wlp \ - && chmod -R g+rw /opt/ibm/wlp - -# Copy the runtime and licenses -COPY --from=getRuntime --chown=1001:0 /opt/ibm/wlp /opt/ibm/wlp -COPY --from=getRuntime /licenses /licenses - -RUN apt-get install -y --no-install-recommends openssl \ + && chmod -R g+rw /opt/ibm/wlp \ + && cp -a /opt/ibm/wlp/lafiles/. /licenses/ \ + && apt-get purge --auto-remove -y unzip \ + && apt-get purge --auto-remove -y wget \ && rm -rf /var/lib/apt/lists/* # Set Path Shortcuts @@ -131,7 +111,7 @@ RUN mkdir /logs \ && rm -rf /output \ && ln -s $WLP_OUTPUT_DIR/defaultServer /output \ && ln -s /opt/ibm/wlp/usr/servers/defaultServer /config \ - && ln -s /opt/ibm /liberty \ + && ln -s /opt/ibm/wlp /liberty \ && ln -s /opt/ibm/fixes /fixes \ && ln -s /opt/ibm/wlp/usr/shared/resources/lib.index.cache /lib.index.cache \ && mkdir -p /config/configDropins/defaults \ diff --git a/ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk17 b/ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk17 index f0bc89464..6bd2eeba2 100644 --- a/ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk17 +++ b/ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk17 @@ -12,33 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM ibm-semeru-runtimes:open-17-jre-focal AS getRuntime - -USER root - -ARG VERBOSE=false - -# Install WebSphere Liberty -ARG LIBERTY_VERSION=23.0.0.7 -ARG LIBERTY_URL -ARG DOWNLOAD_OPTIONS="" - -# If there is a local copy of the image use that instead -COPY resources/ /tmp/ - -RUN apt-get update \ - && apt-get install -y --no-install-recommends unzip wget openssl \ - && rm -rf /var/lib/apt/lists/* \ - && mkdir -p /licenses/ \ - && useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ - && LIBERTY_URL=${LIBERTY_URL:-$(wget -q -O - https://public.dhe.ibm.com/ibmdl/export/pub/software/websphere/wasdev/downloads/wlp/index.yml | grep -E "^\s*kernel:.*${LIBERTY_VERSION}\.zip" | sed -n 's/\s*kernel:\s//p' | tr -d '\r' )} \ - && if [ ! -f /tmp/wlp.zip ]; then wget $DOWNLOAD_OPTIONS $LIBERTY_URL -U UA-IBM-WebSphere-Liberty-Docker -O /tmp/wlp.zip; fi \ - && unzip -q /tmp/wlp.zip -d /opt/ibm \ - && chown -R 1001:0 /opt/ibm/wlp \ - && chmod -R g+rw /opt/ibm/wlp \ - && cp -a /opt/ibm/wlp/lafiles/. /licenses/ - -FROM ibm-semeru-runtimes:open-17-jre-focal +FROM ibm-semeru-runtimes:open-17-jre-jammy USER root @@ -94,17 +68,23 @@ RUN set -eux; \ echo "${DUMB_INIT_SHA256} */usr/bin/dumb-init" | sha256sum -c -; \ chmod +x /usr/bin/dumb-init; -# Add default user 1001 and create wlp with right user/permissions before copying -RUN useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ - && mkdir -p /opt/ibm/wlp \ +# Install WebSphere Liberty +ARG LIBERTY_URL +ARG DOWNLOAD_OPTIONS="" +RUN apt-get update \ + && apt-get install -y --no-install-recommends unzip openssl wget \ + && rm -rf /var/lib/apt/lists/* \ + && mkdir -p /licenses/ \ + && useradd -u 1001 -r -g 0 -s /usr/sbin/nologin default \ + && LIBERTY_URL=${LIBERTY_URL:-$(wget -q -O - https://public.dhe.ibm.com/ibmdl/export/pub/software/websphere/wasdev/downloads/wlp/index.yml | grep -E "^\s*kernel:.*${LIBERTY_VERSION}\.zip" | sed -n 's/\s*kernel:\s//p' | tr -d '\r' )} \ + && wget $DOWNLOAD_OPTIONS $LIBERTY_URL -U UA-IBM-WebSphere-Liberty-Docker -O /tmp/wlp.zip \ + && unzip -q /tmp/wlp.zip -d /opt/ibm \ + && rm /tmp/wlp.zip \ && chown -R 1001:0 /opt/ibm/wlp \ - && chmod -R g+rw /opt/ibm/wlp - -# Copy the runtime and licenses -COPY --from=getRuntime --chown=1001:0 /opt/ibm/wlp /opt/ibm/wlp -COPY --from=getRuntime /licenses /licenses - -RUN apt-get install -y --no-install-recommends openssl \ + && chmod -R g+rw /opt/ibm/wlp \ + && cp -a /opt/ibm/wlp/lafiles/. /licenses/ \ + && apt-get purge --auto-remove -y unzip \ + && apt-get purge --auto-remove -y wget \ && rm -rf /var/lib/apt/lists/* # Set Path Shortcuts @@ -131,7 +111,7 @@ RUN mkdir /logs \ && rm -rf /output \ && ln -s $WLP_OUTPUT_DIR/defaultServer /output \ && ln -s /opt/ibm/wlp/usr/servers/defaultServer /config \ - && ln -s /opt/ibm /liberty \ + && ln -s /opt/ibm/wlp /liberty \ && ln -s /opt/ibm/fixes /fixes \ && ln -s /opt/ibm/wlp/usr/shared/resources/lib.index.cache /lib.index.cache \ && mkdir -p /config/configDropins/defaults \ From 4d89ef04c3b119851496d07f8bcb9847f9fdef35 Mon Sep 17 00:00:00 2001 From: Wendy Raschke Date: Tue, 25 Jul 2023 09:08:24 -0700 Subject: [PATCH 15/19] Remove unnecessary new lines --- ga/latest/kernel/Dockerfile.ubuntu.ibmjava8 | 1 - ga/latest/kernel/Dockerfile.ubuntu.openjdk11 | 1 - ga/latest/kernel/Dockerfile.ubuntu.openjdk17 | 1 - 3 files changed, 3 deletions(-) diff --git a/ga/latest/kernel/Dockerfile.ubuntu.ibmjava8 b/ga/latest/kernel/Dockerfile.ubuntu.ibmjava8 index 7585c56a1..0342ad8bb 100644 --- a/ga/latest/kernel/Dockerfile.ubuntu.ibmjava8 +++ b/ga/latest/kernel/Dockerfile.ubuntu.ibmjava8 @@ -154,4 +154,3 @@ EXPOSE 9080 9443 ENTRYPOINT ["/opt/ibm/helpers/runtime/docker-server.sh"] CMD ["/opt/ibm/wlp/bin/server", "run", "defaultServer"] - diff --git a/ga/latest/kernel/Dockerfile.ubuntu.openjdk11 b/ga/latest/kernel/Dockerfile.ubuntu.openjdk11 index 81df829b9..727d9ad06 100644 --- a/ga/latest/kernel/Dockerfile.ubuntu.openjdk11 +++ b/ga/latest/kernel/Dockerfile.ubuntu.openjdk11 @@ -149,4 +149,3 @@ EXPOSE 9080 9443 ENTRYPOINT ["/opt/ibm/helpers/runtime/docker-server.sh"] CMD ["/opt/ibm/wlp/bin/server", "run", "defaultServer"] - diff --git a/ga/latest/kernel/Dockerfile.ubuntu.openjdk17 b/ga/latest/kernel/Dockerfile.ubuntu.openjdk17 index af3d57d3e..6bd2eeba2 100644 --- a/ga/latest/kernel/Dockerfile.ubuntu.openjdk17 +++ b/ga/latest/kernel/Dockerfile.ubuntu.openjdk17 @@ -149,4 +149,3 @@ EXPOSE 9080 9443 ENTRYPOINT ["/opt/ibm/helpers/runtime/docker-server.sh"] CMD ["/opt/ibm/wlp/bin/server", "run", "defaultServer"] - From 2aa3adfa66226c8409ce8fa9886d272adbd5b237 Mon Sep 17 00:00:00 2001 From: Wendy Raschke Date: Tue, 25 Jul 2023 11:43:24 -0700 Subject: [PATCH 16/19] Updates from PRs 522, 524, and 525 --- ga/23.0.0.7/full/Dockerfile.ubi.ibmjava8 | 4 +--- ga/23.0.0.7/full/Dockerfile.ubi.openjdk11 | 4 +--- ga/23.0.0.7/full/Dockerfile.ubi.openjdk17 | 4 +--- ga/23.0.0.7/full/Dockerfile.ubi.openjdk8 | 4 +--- ga/23.0.0.7/kernel/Dockerfile.ubi.ibmjava8 | 2 +- ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk11 | 2 +- ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk17 | 2 +- ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk8 | 2 +- ga/23.0.0.7/kernel/helpers/build/populate_scc.sh | 6 ++++-- 9 files changed, 12 insertions(+), 18 deletions(-) diff --git a/ga/23.0.0.7/full/Dockerfile.ubi.ibmjava8 b/ga/23.0.0.7/full/Dockerfile.ubi.ibmjava8 index 7459b92eb..e2fac8612 100644 --- a/ga/23.0.0.7/full/Dockerfile.ubi.ibmjava8 +++ b/ga/23.0.0.7/full/Dockerfile.ubi.ibmjava8 @@ -15,8 +15,6 @@ ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:23.0.0.7-kernel-java8-ibmjava-ubi FROM $PARENT_IMAGE AS installBundle -USER root - ARG VERBOSE=false ARG REPOSITORIES_PROPERTIES="" @@ -43,7 +41,7 @@ FROM $PARENT_IMAGE ARG VERBOSE=false # Copy the runtime -COPY --from=installBundle /opt/ibm/wlp /opt/ibm/wlp +COPY --from=installBundle --chown=1001:0 /opt/ibm/wlp /opt/ibm/wlp COPY --chown=1001:0 server.xml /config/ diff --git a/ga/23.0.0.7/full/Dockerfile.ubi.openjdk11 b/ga/23.0.0.7/full/Dockerfile.ubi.openjdk11 index 7ea47011f..5e01f9c49 100644 --- a/ga/23.0.0.7/full/Dockerfile.ubi.openjdk11 +++ b/ga/23.0.0.7/full/Dockerfile.ubi.openjdk11 @@ -15,8 +15,6 @@ ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:23.0.0.7-kernel-java11-openj9-ubi FROM $PARENT_IMAGE AS installBundle -USER root - ARG VERBOSE=false ARG REPOSITORIES_PROPERTIES="" @@ -43,7 +41,7 @@ FROM $PARENT_IMAGE ARG VERBOSE=false # Copy the runtime -COPY --from=installBundle /opt/ibm/wlp /opt/ibm/wlp +COPY --from=installBundle --chown=1001:0 /opt/ibm/wlp /opt/ibm/wlp COPY --chown=1001:0 server.xml /config/ diff --git a/ga/23.0.0.7/full/Dockerfile.ubi.openjdk17 b/ga/23.0.0.7/full/Dockerfile.ubi.openjdk17 index d7911fdba..96a3d85a2 100644 --- a/ga/23.0.0.7/full/Dockerfile.ubi.openjdk17 +++ b/ga/23.0.0.7/full/Dockerfile.ubi.openjdk17 @@ -15,8 +15,6 @@ ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:23.0.0.7-kernel-java17-openj9-ubi FROM $PARENT_IMAGE AS installBundle -USER root - ARG VERBOSE=false ARG REPOSITORIES_PROPERTIES="" @@ -43,7 +41,7 @@ FROM $PARENT_IMAGE ARG VERBOSE=false # Copy the runtime -COPY --from=installBundle /opt/ibm/wlp /opt/ibm/wlp +COPY --from=installBundle --chown=1001:0 /opt/ibm/wlp /opt/ibm/wlp COPY --chown=1001:0 server.xml /config/ diff --git a/ga/23.0.0.7/full/Dockerfile.ubi.openjdk8 b/ga/23.0.0.7/full/Dockerfile.ubi.openjdk8 index 420ecdb24..b1601394c 100644 --- a/ga/23.0.0.7/full/Dockerfile.ubi.openjdk8 +++ b/ga/23.0.0.7/full/Dockerfile.ubi.openjdk8 @@ -15,8 +15,6 @@ ARG PARENT_IMAGE=icr.io/appcafe/websphere-liberty:23.0.0.7-kernel-java8-openj9-ubi FROM $PARENT_IMAGE AS installBundle -USER root - ARG VERBOSE=false ARG REPOSITORIES_PROPERTIES="" @@ -43,7 +41,7 @@ FROM $PARENT_IMAGE ARG VERBOSE=false # Copy the runtime -COPY --from=installBundle /opt/ibm/wlp /opt/ibm/wlp +COPY --from=installBundle --chown=1001:0 /opt/ibm/wlp /opt/ibm/wlp COPY --chown=1001:0 server.xml /config/ diff --git a/ga/23.0.0.7/kernel/Dockerfile.ubi.ibmjava8 b/ga/23.0.0.7/kernel/Dockerfile.ubi.ibmjava8 index 9d5ac1c1e..0218db758 100644 --- a/ga/23.0.0.7/kernel/Dockerfile.ubi.ibmjava8 +++ b/ga/23.0.0.7/kernel/Dockerfile.ubi.ibmjava8 @@ -135,7 +135,7 @@ RUN mkdir /logs \ && rm -rf /output \ && ln -s $WLP_OUTPUT_DIR/defaultServer /output \ && ln -s /opt/ibm/wlp/usr/servers/defaultServer /config \ - && ln -s /opt/ibm /liberty \ + && ln -s /opt/ibm/wlp /liberty \ && ln -s /opt/ibm/fixes /fixes \ && ln -s /opt/ibm/wlp/usr/shared/resources/lib.index.cache /lib.index.cache \ && mkdir -p /config/configDropins/defaults \ diff --git a/ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk11 b/ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk11 index cbd5df5ec..f66d9290f 100644 --- a/ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk11 +++ b/ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk11 @@ -135,7 +135,7 @@ RUN mkdir /logs \ && rm -rf /output \ && ln -s $WLP_OUTPUT_DIR/defaultServer /output \ && ln -s /opt/ibm/wlp/usr/servers/defaultServer /config \ - && ln -s /opt/ibm /liberty \ + && ln -s /opt/ibm/wlp /liberty \ && ln -s /opt/ibm/fixes /fixes \ && ln -s /opt/ibm/wlp/usr/shared/resources/lib.index.cache /lib.index.cache \ && mkdir -p /config/configDropins/defaults \ diff --git a/ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk17 b/ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk17 index bdf26a8a1..16c4e5cc8 100644 --- a/ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk17 +++ b/ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk17 @@ -135,7 +135,7 @@ RUN mkdir /logs \ && rm -rf /output \ && ln -s $WLP_OUTPUT_DIR/defaultServer /output \ && ln -s /opt/ibm/wlp/usr/servers/defaultServer /config \ - && ln -s /opt/ibm /liberty \ + && ln -s /opt/ibm/wlp /liberty \ && ln -s /opt/ibm/fixes /fixes \ && ln -s /opt/ibm/wlp/usr/shared/resources/lib.index.cache /lib.index.cache \ && mkdir -p /config/configDropins/defaults \ diff --git a/ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk8 b/ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk8 index 2484c6586..12492aa28 100644 --- a/ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk8 +++ b/ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk8 @@ -135,7 +135,7 @@ RUN mkdir /logs \ && rm -rf /output \ && ln -s $WLP_OUTPUT_DIR/defaultServer /output \ && ln -s /opt/ibm/wlp/usr/servers/defaultServer /config \ - && ln -s /opt/ibm /liberty \ + && ln -s /opt/ibm/wlp /liberty \ && ln -s /opt/ibm/fixes /fixes \ && ln -s /opt/ibm/wlp/usr/shared/resources/lib.index.cache /lib.index.cache \ && mkdir -p /config/configDropins/defaults \ diff --git a/ga/23.0.0.7/kernel/helpers/build/populate_scc.sh b/ga/23.0.0.7/kernel/helpers/build/populate_scc.sh index 8f65ec392..3c07a4e92 100755 --- a/ga/23.0.0.7/kernel/helpers/build/populate_scc.sh +++ b/ga/23.0.0.7/kernel/helpers/build/populate_scc.sh @@ -97,7 +97,8 @@ if [ $TRIM_SCC == yes ] then echo "Calculating SCC layer upper bound, starting with initial size $SCC_SIZE." # Populate the newly created class cache layer. - /opt/ibm/wlp/bin/server start && /opt/ibm/wlp/bin/server stop + /opt/ibm/wlp/bin/server start + /opt/ibm/wlp/bin/server stop # Find out how full it is. FULL=`( java $PRINT_LAYER_STATS || true ) 2>&1 | awk '/^Cache is [0-9.]*% .*full/ {print substr($3, 1, length($3)-1)}'` echo "SCC layer is $FULL% full. Destroying layer." @@ -120,7 +121,8 @@ fi # Server start/stop to populate the /output/workarea and make subsequent server starts faster. for ((i=0; i<$ITERATIONS; i++)) do - /opt/ibm/wlp/bin/server start && /opt/ibm/wlp/bin/server stop + /opt/ibm/wlp/bin/server start + /opt/ibm/wlp/bin/server stop done # restore umask From 3b034d8a78d5fac4b6824cd0cd6b12be28467cc8 Mon Sep 17 00:00:00 2001 From: Wendy Raschke Date: Tue, 25 Jul 2023 15:43:33 -0700 Subject: [PATCH 17/19] Unnecessary whitespace at end of line --- ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk11 | 2 +- ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk17 | 2 +- ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk8 | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk11 b/ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk11 index f66d9290f..b5882d924 100644 --- a/ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk11 +++ b/ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk11 @@ -135,7 +135,7 @@ RUN mkdir /logs \ && rm -rf /output \ && ln -s $WLP_OUTPUT_DIR/defaultServer /output \ && ln -s /opt/ibm/wlp/usr/servers/defaultServer /config \ - && ln -s /opt/ibm/wlp /liberty \ + && ln -s /opt/ibm/wlp /liberty \ && ln -s /opt/ibm/fixes /fixes \ && ln -s /opt/ibm/wlp/usr/shared/resources/lib.index.cache /lib.index.cache \ && mkdir -p /config/configDropins/defaults \ diff --git a/ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk17 b/ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk17 index 16c4e5cc8..569932d85 100644 --- a/ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk17 +++ b/ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk17 @@ -135,7 +135,7 @@ RUN mkdir /logs \ && rm -rf /output \ && ln -s $WLP_OUTPUT_DIR/defaultServer /output \ && ln -s /opt/ibm/wlp/usr/servers/defaultServer /config \ - && ln -s /opt/ibm/wlp /liberty \ + && ln -s /opt/ibm/wlp /liberty \ && ln -s /opt/ibm/fixes /fixes \ && ln -s /opt/ibm/wlp/usr/shared/resources/lib.index.cache /lib.index.cache \ && mkdir -p /config/configDropins/defaults \ diff --git a/ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk8 b/ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk8 index 12492aa28..90927869d 100644 --- a/ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk8 +++ b/ga/23.0.0.7/kernel/Dockerfile.ubi.openjdk8 @@ -135,7 +135,7 @@ RUN mkdir /logs \ && rm -rf /output \ && ln -s $WLP_OUTPUT_DIR/defaultServer /output \ && ln -s /opt/ibm/wlp/usr/servers/defaultServer /config \ - && ln -s /opt/ibm/wlp /liberty \ + && ln -s /opt/ibm/wlp /liberty \ && ln -s /opt/ibm/fixes /fixes \ && ln -s /opt/ibm/wlp/usr/shared/resources/lib.index.cache /lib.index.cache \ && mkdir -p /config/configDropins/defaults \ From e0ba7f7749404f117ca22c1931d43280db87b5b1 Mon Sep 17 00:00:00 2001 From: Leo Christy Jesuraj Date: Thu, 27 Jul 2023 09:05:31 -0400 Subject: [PATCH 18/19] Switch back to focal (#528) Signed-off-by: Leo Christy Jesuraj --- ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk11 | 2 +- ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk17 | 2 +- ga/latest/kernel/Dockerfile.ubuntu.openjdk11 | 2 +- ga/latest/kernel/Dockerfile.ubuntu.openjdk17 | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk11 b/ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk11 index 727d9ad06..0ce1a057d 100644 --- a/ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk11 +++ b/ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk11 @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM ibm-semeru-runtimes:open-11-jre-jammy +FROM ibm-semeru-runtimes:open-11-jre-focal USER root diff --git a/ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk17 b/ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk17 index 6bd2eeba2..74ddf2823 100644 --- a/ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk17 +++ b/ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk17 @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM ibm-semeru-runtimes:open-17-jre-jammy +FROM ibm-semeru-runtimes:open-17-jre-focal USER root diff --git a/ga/latest/kernel/Dockerfile.ubuntu.openjdk11 b/ga/latest/kernel/Dockerfile.ubuntu.openjdk11 index 727d9ad06..0ce1a057d 100644 --- a/ga/latest/kernel/Dockerfile.ubuntu.openjdk11 +++ b/ga/latest/kernel/Dockerfile.ubuntu.openjdk11 @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM ibm-semeru-runtimes:open-11-jre-jammy +FROM ibm-semeru-runtimes:open-11-jre-focal USER root diff --git a/ga/latest/kernel/Dockerfile.ubuntu.openjdk17 b/ga/latest/kernel/Dockerfile.ubuntu.openjdk17 index 6bd2eeba2..74ddf2823 100644 --- a/ga/latest/kernel/Dockerfile.ubuntu.openjdk17 +++ b/ga/latest/kernel/Dockerfile.ubuntu.openjdk17 @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM ibm-semeru-runtimes:open-17-jre-jammy +FROM ibm-semeru-runtimes:open-17-jre-focal USER root From a6cad848817455d95deb0e8f60aad76b906580cc Mon Sep 17 00:00:00 2001 From: Leo Christy Jesuraj Date: Fri, 28 Jul 2023 07:40:06 -0400 Subject: [PATCH 19/19] Switch Ubuntu based images for 23.0.0.7 and above to jammy (22.04) Signed-off-by: Leo Christy Jesuraj --- ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk11 | 2 +- ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk17 | 2 +- ga/latest/kernel/Dockerfile.ubuntu.openjdk11 | 2 +- ga/latest/kernel/Dockerfile.ubuntu.openjdk17 | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk11 b/ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk11 index 0ce1a057d..727d9ad06 100644 --- a/ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk11 +++ b/ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk11 @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM ibm-semeru-runtimes:open-11-jre-focal +FROM ibm-semeru-runtimes:open-11-jre-jammy USER root diff --git a/ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk17 b/ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk17 index 74ddf2823..6bd2eeba2 100644 --- a/ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk17 +++ b/ga/23.0.0.7/kernel/Dockerfile.ubuntu.openjdk17 @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM ibm-semeru-runtimes:open-17-jre-focal +FROM ibm-semeru-runtimes:open-17-jre-jammy USER root diff --git a/ga/latest/kernel/Dockerfile.ubuntu.openjdk11 b/ga/latest/kernel/Dockerfile.ubuntu.openjdk11 index 0ce1a057d..727d9ad06 100644 --- a/ga/latest/kernel/Dockerfile.ubuntu.openjdk11 +++ b/ga/latest/kernel/Dockerfile.ubuntu.openjdk11 @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM ibm-semeru-runtimes:open-11-jre-focal +FROM ibm-semeru-runtimes:open-11-jre-jammy USER root diff --git a/ga/latest/kernel/Dockerfile.ubuntu.openjdk17 b/ga/latest/kernel/Dockerfile.ubuntu.openjdk17 index 74ddf2823..6bd2eeba2 100644 --- a/ga/latest/kernel/Dockerfile.ubuntu.openjdk17 +++ b/ga/latest/kernel/Dockerfile.ubuntu.openjdk17 @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM ibm-semeru-runtimes:open-17-jre-focal +FROM ibm-semeru-runtimes:open-17-jre-jammy USER root