Skip to content

Coherence Certification #1942

Coherence Certification

Coherence Certification #1942

# Copyright 2021, 2024, Oracle Corporation and/or its affiliates. All rights reserved.
# Licensed under the Universal Permissive License v 1.0 as shown at
# http://oss.oracle.com/licenses/upl.
# ---------------------------------------------------------------------------
# Coherence Operator GitHub Actions Coherence Certification build.
# ---------------------------------------------------------------------------
name: Coherence Certification
on:
workflow_dispatch:
schedule:
- cron: '0 0 * * *'
push:
branches-ignore:
- gh-pages
- 1.0.0
- 2.x
- 3.x
env:
MAVEN_USER: ${{ secrets.MAVEN_USER }}
MAVEN_PASSWORD: ${{ secrets.MAVEN_PASSWORD }}
LOAD_KIND: true
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
jobs:
build:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
matrixName:
- "15.1.1-0-SNAPSHOT"
- "15.1.1-0-SNAPSHOT-Graal"
- "24.09"
- "24.09-Graal"
- "22.06"
- "14.1.2-0-SNAPSHOT"
- "14.1.1-2206-SNAPSHOT"
- "14.1.1-0-SNAPSHOT"
- "14.1.1-0"
- "14.1.1.0.0"
- "12.2.1.4.0"
- "12.2.1-4-SNAPSHOT"
include:
- matrixName: "15.1.1-0-SNAPSHOT"
coherenceVersion: "15.1.1-0-0-SNAPSHOT"
coherenceImage: "iad.ocir.io/odx-stateservice/test/coherence:15.1.1-0-0-SNAPSHOT-java17"
javaVersion: 17
baseImage: "gcr.io/distroless/java17-debian12"
- matrixName: "15.1.1-0-SNAPSHOT-Graal"
coherenceVersion: "15.1.1-0-0-SNAPSHOT"
coherenceImage: "iad.ocir.io/odx-stateservice/test/coherence:15.1.1-0-0-SNAPSHOT-graal"
javaVersion: 17
baseImage: "gcr.io/distroless/java17-debian12"
- matrixName: "24.09"
coherenceVersion: "24.09"
coherenceImage: "ghcr.io/oracle/coherence-ce:24.09"
javaVersion: 17
baseImage: "gcr.io/distroless/java17-debian12"
- matrixName: "24.09-Graal"
coherenceVersion: "24.09"
coherenceImage: "ghcr.io/oracle/coherence-ce:24.09-graal"
javaVersion: 17
baseImage: "gcr.io/distroless/java17-debian12"
- matrixName: "22.06"
coherenceVersion: "22.06.10"
coherenceImage: "ghcr.io/oracle/coherence-ce:22.06.10"
javaVersion: 11
baseImage: "gcr.io/distroless/java11-debian11"
- matrixName: "14.1.2-0-SNAPSHOT"
coherenceVersion: "14.1.2-0-0-SNAPSHOT"
coherenceImage: "iad.ocir.io/odx-stateservice/test/coherence:14.1.2-0-0-SNAPSHOT"
javaVersion: 17
baseImage: "gcr.io/distroless/java17-debian12"
- matrixName: "14.1.1-2206-SNAPSHOT"
coherenceVersion: "14.1.1-2206-10-SNAPSHOT"
coherenceImage: "iad.ocir.io/odx-stateservice/test/coherence:14.1.1-2206-10-SNAPSHOT"
javaVersion: 11
baseImage: "gcr.io/distroless/java11-debian11"
- matrixName: "14.1.1-0-SNAPSHOT"
coherenceVersion: "14.1.1-0-20-SNAPSHOT"
coherenceImage: "iad.ocir.io/odx-stateservice/test/coherence:14.1.1-0-19-SNAPSHOT"
javaVersion: 8
baseImage: "gcr.io/distroless/java11-debian11"
- matrixName: "14.1.1-0"
coherenceVersion: "14.1.1-0-19"
javaVersion: 8
coherenceImage: "ghcr.io/oracle/coherence-ce:14.1.1-0-19"
baseImage: "gcr.io/distroless/java11-debian11"
- matrixName: "14.1.1.0.0"
coherenceVersion: "14.1.1.0.0"
coherenceImage: "container-registry.oracle.com/middleware/coherence:14.1.1.0.0"
javaVersion: 8
baseImage: "gcr.io/distroless/java11-debian11"
- matrixName: "12.2.1.4.0"
coherenceVersion: "12.2.1.4.0"
coherenceImage: "container-registry.oracle.com/middleware/coherence:12.2.1.4.0"
javaVersion: 8
baseImage: "gcr.io/distroless/java11-debian11"
- matrixName: "12.2.1-4-SNAPSHOT"
coherenceVersion: "12.2.1-4-24-SNAPSHOT"
coherenceImage: "iad.ocir.io/odx-stateservice/test/coherence:12.2.1-4-24-SNAPSHOT"
javaVersion: 8
baseImage: "gcr.io/distroless/java11-debian11"
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
# This step will free up disc space on the runner by removing
# lots of things that we do not need.
- name: disc
shell: bash
run: |
echo "Listing 100 largest packages"
dpkg-query -Wf '${Installed-Size}\t${Package}\n' | sort -n | tail -n 100
df -h
echo "Removing large packages"
sudo apt-get remove -y '^dotnet-.*' || true
sudo apt-get remove -y '^llvm-.*' || true
sudo apt-get remove -y 'monodoc-http' || true
sudo apt-get remove -y 'php.*' || true
sudo apt-get remove -y azure-cli google-cloud-sdk hhvm google-chrome-stable firefox powershell mono-devel || true
sudo apt-get autoremove -y || true
sudo apt-get clean
df -h
echo "Removing large directories"
sudo rm -rf /usr/share/dotnet/
sudo rm -rf /usr/local/lib/android
df -h
- name: Set up JDK
uses: oracle-actions/setup-java@v1
with:
website: oracle.com
release: 21
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: 1.22.x
- name: Cache Go Modules
uses: actions/cache@v4
with:
path: ~/go/pkg/mod
key: ${{ runner.os }}-go-mods-${{ hashFiles('**/go.sum') }}
restore-keys: |
${{ runner.os }}-go-mods-
- name: Cache Maven packages
uses: actions/cache@v4
with:
path: ~/.m2
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
restore-keys: ${{ runner.os }}-m2
- name: Edit DNS Resolve
shell: bash
run: |
sudo chown -R runner:runner /run/systemd/resolve/stub-resolv.conf
sudo echo nameserver 8.8.8.8 > /run/systemd/resolve/stub-resolv.conf
- name: Start KinD Cluster
shell: bash
run: |
make kind
kubectl version
kubectl get nodes
echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io -u $ --password-stdin
docker login container-registry.oracle.com -u "${{ secrets.OCR_DOCKER_USERNAME }}" -p "${{ secrets.OCR_DOCKER_PASSWORD }}"
docker login "${{ secrets.OCI_REGISTRY }}" -u "${{ secrets.OCI_USERNAME }}" -p "${{ secrets.OCI_PASSWORD }}"
docker pull gcr.io/distroless/java
docker pull gcr.io/distroless/java11-debian11
docker pull gcr.io/distroless/java17-debian11
docker pull ${{ matrix.coherenceImage }}
- name: Coherence Certification Tests
shell: bash
run: |
export COHERENCE_IMAGE=${{ matrix.coherenceImage }}
echo "COHERENCE_IMAGE=${COHERENCE_IMAGE}"
export BUILD_JAVA_VERSION=${{ matrix.javaVersion }}
echo "BUILD_JAVA_VERSION=${BUILD_JAVA_VERSION}"
export COHERENCE_TEST_BASE_IMAGE=${{ matrix.baseImage }}
echo "COHERENCE_TEST_BASE_IMAGE=${COHERENCE_TEST_BASE_IMAGE}"
make clean
echo "Building Operator Image"
make build-operator-images
echo "Building Coherence Compatibility Image"
make build-compatibility-image
echo "Loading Images to Kind"
make kind-load
make kind-load-compatibility
echo "Running Coherence Compatibility Tests"
export TEST_LOGS_DIR=build/_output/test-logs/${{ matrix.matrixName }}
make coherence-compatibility-test
- uses: actions/upload-artifact@v4
if: ${{ failure() || cancelled() }}
with:
name: test-output-${{ matrix.matrixName }}
path: build/_output/test-logs
if-no-files-found: ignore