diff --git a/library/glassfish b/library/glassfish new file mode 100644 index 0000000000000..762eaa909f197 --- /dev/null +++ b/library/glassfish @@ -0,0 +1,54 @@ +Maintainers: David Matejcek (@dmatej), + Arjan Tijms (@arjantijms), + Ondro Mihalyi (@ondromih) +GitRepo: https://github.com/eclipse-ee4j/glassfish.docker.git +GitFetch: refs/heads/main +GitCommit: 4507192e8332614e653d9a0394eb5c94955c1bfe + +Tags: 7.0.8, 7.0.8-jdk17, 7.0.8-jdk17-eclipse-temurin +Architectures: amd64, arm64v8 +Directory: 7.0.8 + +Tags: 7.0.9, 7.0.9-jdk17, 7.0.9-jdk17-eclipse-temurin +Architectures: amd64, arm64v8 +Directory: 7.0.9 + +Tags: 7.0.10, 7.0.10-jdk17, 7.0.10-jdk17-eclipse-temurin +Architectures: amd64, arm64v8 +Directory: 7.0.10 + +Tags: 7.0.11, 7.0.11-jdk17, 7.0.11-jdk17-eclipse-temurin +Architectures: amd64, arm64v8 +Directory: 7.0.11 + +Tags: 7.0.12, 7.0.12-jdk17, 7.0.12-jdk17-eclipse-temurin +Architectures: amd64, arm64v8 +Directory: 7.0.12 + +Tags: 7.0.13, 7.0.13-jdk17, 7.0.13-jdk17-eclipse-temurin +Architectures: amd64, arm64v8 +Directory: 7.0.13 + +Tags: 7.0.14, 7.0.14-jdk17, 7.0.14-jdk17-eclipse-temurin +Architectures: amd64, arm64v8 +Directory: 7.0.14 + +Tags: 7.0.15, 7.0.15-jdk17, 7.0.15-jdk17-eclipse-temurin +Architectures: amd64, arm64v8 +Directory: 7.0.15 + +Tags: 7.0.16, 7.0.16-jdk17, 7.0.16-jdk17-eclipse-temurin +Architectures: amd64, arm64v8 +Directory: 7.0.16 + +Tags: 7.0.17, 7.0.17-jdk17, 7.0.17-jdk17-eclipse-temurin +Architectures: amd64, arm64v8 +Directory: 7.0.17 + +Tags: 7.0.18, 7.0.18-jdk17, 7.0.18-jdk17-eclipse-temurin +Architectures: amd64, arm64v8 +Directory: 7.0.18 + +Tags: latest, 7.0.19, 7.0.19-jdk17, 7.0.19-jdk17-eclipse-temurin +Architectures: amd64, arm64v8 +Directory: 7.0.19 diff --git a/test/config.sh b/test/config.sh index 257b13b6ccc01..f27c233cb35b9 100644 --- a/test/config.sh +++ b/test/config.sh @@ -76,6 +76,9 @@ imageTests+=( [ghost]=' ghost-basics ' + [glassfish]=' + glassfish + ' [golang]=' golang-hello-world ' diff --git a/test/tests/glassfish/run.sh b/test/tests/glassfish/run.sh new file mode 100755 index 0000000000000..6119babda7575 --- /dev/null +++ b/test/tests/glassfish/run.sh @@ -0,0 +1,27 @@ +#!/bin/bash +set -eo pipefail + +serverImage="$1" +containerId="$(docker run -d "$serverImage")" +trap "docker rm -vf $containerId > /dev/null" EXIT + +waitForLogLine() { + timeout="$1"; + logLine="$2"; + until docker logs $containerId 2>&1 | grep -q -E "$logLine" + do + if [ $timeout -eq 0 ] + then + exit 100; + fi + sleep 1 + timeout=$((timeout-1)) + done +} + +waitForLogLine 60 '^\s+Eclipse GlassFish\s+[\.0-9]+'; +echo "GlassFish started as ${containerId}" + +docker stop "${containerId}" & +waitForLogLine 30 '^\s*Completed shutdown of GlassFish runtime'; +echo "GlassFish stopped OK!"