From f3af0f8975b31ed5bce3a7b5f5f68e16d1860746 Mon Sep 17 00:00:00 2001 From: Daniel Arroyo Date: Wed, 12 Aug 2026 16:33:02 -0400 Subject: [PATCH] fix(ci): install Maven in each job (runner has no mvn binary) The runner has Java (via setup-java) but no Maven. Add an Install Maven step to build-jvm and build-native that downloads Maven 3.9.6 from Apache to runner.workspace/.maven and adds it to the PATH via $GITHUB_PATH. Idempotent: the if-guard skips redownload if the binary already exists on the runner. --- .gitea/workflows/ci.yml | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/.gitea/workflows/ci.yml b/.gitea/workflows/ci.yml index 698ab8d..579b0dd 100644 --- a/.gitea/workflows/ci.yml +++ b/.gitea/workflows/ci.yml @@ -28,6 +28,18 @@ jobs: java-version: 21 cache: maven + - name: Install Maven + env: + MAVEN_VERSION: 3.9.6 + MAVEN_HOME: ${{ runner.workspace }}/.maven + run: | + mkdir -p "$MAVEN_HOME" + if [ ! -x "$MAVEN_HOME/bin/mvn" ]; then + curl -fsSL "https://archive.apache.org/dist/maven/maven-3/$MAVEN_VERSION/binaries/apache-maven-$MAVEN_VERSION-bin.tar.gz" | tar -xz -C "$MAVEN_HOME" --strip-components=1 + fi + echo "$MAVEN_HOME/bin" >> "$GITHUB_PATH" + mvn --version + - name: Cache Node + npm uses: actions/cache@v4 with: @@ -60,6 +72,18 @@ jobs: java-version: 21 cache: maven + - name: Install Maven + env: + MAVEN_VERSION: 3.9.6 + MAVEN_HOME: ${{ runner.workspace }}/.maven + run: | + mkdir -p "$MAVEN_HOME" + if [ ! -x "$MAVEN_HOME/bin/mvn" ]; then + curl -fsSL "https://archive.apache.org/dist/maven/maven-3/$MAVEN_VERSION/binaries/apache-maven-$MAVEN_VERSION-bin.tar.gz" | tar -xz -C "$MAVEN_HOME" --strip-components=1 + fi + echo "$MAVEN_HOME/bin" >> "$GITHUB_PATH" + mvn --version + - name: Set up GraalVM uses: graalvm/setup-graalvm@v1 with: