From: J. Eric Ivancich Date: Mon, 9 Dec 2024 22:23:59 +0000 (-0500) Subject: qa/rgw: force s3 java tests to run gradle on Java 8 X-Git-Tag: v18.2.5~169^2 X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=b52830985ae9ed6f90403632eaf7f48d581b8bbe;p=ceph.git qa/rgw: force s3 java tests to run gradle on Java 8 Previously gradle would run using the default Java version. This looks for Java 8 using `alternatives` and sets JAVA_HOME to the corresponding directory prior to launching gradle. Signed-off-by: J. Eric Ivancich (cherry picked from commit 1c2954648362c450c3e90fa6b72814de8eeeafa2) --- diff --git a/qa/tasks/s3tests_java.py b/qa/tasks/s3tests_java.py index 6aa88c12e2f98..fd1f6e3b5121c 100644 --- a/qa/tasks/s3tests_java.py +++ b/qa/tasks/s3tests_java.py @@ -284,6 +284,7 @@ class S3tests_java(Task): args = ['cd', '{tdir}/s3-tests-java'.format(tdir=testdir), run.Raw('&&'), + run.Raw('JAVA_HOME=$(alternatives --list | grep jre_1.8.0 | head -n 1 | awk \'{print $3}\')'), '/opt/gradle/gradle/bin/gradle', 'clean', 'test', '--rerun-tasks', '--no-build-cache', ]