Fix: Add JDK configuration step in Gradle jobs 66/71866/1 v0.87.1
authorJessica Wagantall <jwagantall@linuxfoundation.org>
Fri, 23 Jun 2023 17:09:32 +0000 (10:09 -0700)
committerJessica Wagantall <jwagantall@linuxfoundation.org>
Fri, 23 Jun 2023 17:09:32 +0000 (10:09 -0700)
Issue: RELENG-4769
Signed-off-by: Jessica Wagantall <jwagantall@linuxfoundation.org>
Change-Id: I50eb766d7b60e8da8ff3eafbda1d9fc4f2e817ca

docs/jjb/lf-gradle-jobs.rst
jjb/lf-gradle-jobs.yaml
releasenotes/notes/add-lf-gradle-jdk-c32197ce5806ccef.yaml [new file with mode: 0644]

index 98841d1..3bc0c34 100644 (file)
@@ -18,6 +18,7 @@ Runs a gradle build command to perform the verification.
 
 :Required parameters:
     :build-node:    The node to run build on.
+    :java-version: Version of Java to execute Maven build. (default: openjdk17)
     :jenkins-ssh-credential: Credential to use for SSH. (Generally configured in defaults.yaml)
 
 :Optional parameters:
index 424d83e..cd4f4d6 100644 (file)
@@ -77,6 +77,9 @@
     <<: *lf_gradle_common
 
     builders:
+      - lf-infra-pre-build
+      - lf-update-java-alternatives:
+          java-version: "{java-version}"
       - shell: |
           ./gradlew build
 
diff --git a/releasenotes/notes/add-lf-gradle-jdk-c32197ce5806ccef.yaml b/releasenotes/notes/add-lf-gradle-jdk-c32197ce5806ccef.yaml
new file mode 100644 (file)
index 0000000..c0909ae
--- /dev/null
@@ -0,0 +1,4 @@
+---
+fixes:
+  - |
+    Add a JDK configuration step in the Gradle based jobs.