ci-runner-test/.gitea/workflows/test-ci-runner.yml
Dave the Dev 455505a6d6 Hithomelabs/HomeLabDocker#76: Fix Gradle build failure — replace setup-java with Alpine JDK package
The actions/setup-java@v4 step downloads a glibc-compiled JDK (Temurin)
which cannot execute on Alpine's musl libc. Replace with Alpine's native
openjdk17-jdk package via apk, which is compiled for musl and works
correctly with gradlew.
2026-07-05 06:27:45 +00:00

40 lines
1019 B
YAML

name: Test CI Runner Image
on:
push:
branches: [test, main]
workflow_dispatch:
jobs:
validate:
runs-on: ubuntu-latest
container:
image: 192.168.0.100:8928/hithomelabs/ci-runner:latest
steps:
- uses: actions/checkout@v4
- name: Install JDK (musl-native, Alpine package)
run: |
apk add --no-cache openjdk17-jdk
echo "JAVA_HOME=/usr/lib/jvm/java-17-openjdk" >> "$GITHUB_ENV"
- name: Verify tools
run: |
echo "=== Java (should be JDK 17) ==="
java -version
echo "=== Docker ==="
docker --version
echo "=== Git ==="
git --version
echo "=== Node.js ==="
node --version
- name: Gradle build
run: ./gradlew build
- name: Test Docker CLI (socket mount)
run: |
echo "FROM alpine:latest" > Dockerfile.test
docker build -t test-image . -f Dockerfile.test
docker rmi test-image
rm Dockerfile.test