del
Some checks failed
checks / Set up Node and other necessary dependencies for Frontend Tests and Build (push) Successful in 11s
checks / Set up Java for Backend Tests and Build (push) Failing after 6s
Gitea Actions Demo / Explore-Gitea-Actions (pull_request) Successful in 2s
Gitea Actions Demo / Explore-Gitea-Actions-2 (pull_request) Successful in 2s
checks / Set up Node and other necessary dependencies for Frontend Tests and Build (pull_request) Successful in 11s
checks / Set up Java for Backend Tests and Build (pull_request) Failing after 6s

This commit is contained in:
Patrick
2025-10-31 11:04:14 +01:00
parent 2ebd6a6a95
commit 993c8413cc

View File

@ -109,41 +109,6 @@ jobs:
fi fi
shell: bash shell: bash
- name: Install OpenJDK 21
shell: bash
run: |
set -e
# Check if apt-get exists; if not, install it
if ! command -v apt-get &> /dev/null; then
echo "apt-get not found. Attempting to install..."
if command -v apk &> /dev/null; then
echo "Using apk to install apt (Alpine detected)..."
apk update
apk add --no-cache apt
elif command -v dnf &> /dev/null; then
echo "Using dnf (Fedora/RHEL detected)..."
dnf install -y apt
elif command -v yum &> /dev/null; then
echo "Using yum (CentOS/RHEL detected)..."
yum install -y apt
else
echo "No supported package manager found!"
exit 1
fi
fi
# Continue installation using apt-get
apt-get update -y
apt-get install -y apt-transport-https ca-certificates curl gnupg wget software-properties-common
# Download and install Oracle JDK 21
wget https://download.oracle.com/java/21/latest/jdk-21_linux-x64_bin.deb
apt install -y ./jdk-21_linux-x64_bin.deb
# Verify installation
java -version
- uses: actions/checkout@v5 - uses: actions/checkout@v5
- name: Set up JDK 21 for x64 - name: Set up JDK 21 for x64
uses: actions/setup-java@v4 uses: actions/setup-java@v4