This is an automated email from the ASF dual-hosted git repository. jason810496 pushed a commit to branch jason/lang-sdk-e2e/08-native-e2e in repository https://gitbox.apache.org/repos/asf/airflow.git
commit 6707aa83b8c998f416858c50ab0fbb05b2a21ff5 Author: ZHE YOU LIU <[email protected]> AuthorDate: Mon Sep 28 08:01:29 2026 +0000 Keep the containerized Java build's Maven repository on the host The JVM takes user.home from /etc/passwd, so when the host UID is one the JDK image defines (1000 is its "ubuntu" user), publishToMavenLocal wrote into the container and the example builds could not find the SDK. Name the mounted repository with maven.repo.local instead of relying on HOME. --- airflow-e2e-tests/tests/airflow_e2e_tests/conftest.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/airflow-e2e-tests/tests/airflow_e2e_tests/conftest.py b/airflow-e2e-tests/tests/airflow_e2e_tests/conftest.py index 4b441bb549f..3fd6f9a6b6e 100644 --- a/airflow-e2e-tests/tests/airflow_e2e_tests/conftest.py +++ b/airflow-e2e-tests/tests/airflow_e2e_tests/conftest.py @@ -319,6 +319,9 @@ def _run_java_sdk_gradle(workdir, *gradle_argv, capture_output=False, native=Fal image's HOME (/root) which the non-root process cannot write to. * files/m2 is mounted directly as ~/.m2 so publishToMavenLocal writes there without nesting, and its contents are visible on the host. + maven.repo.local names it explicitly: the JVM takes its home from + /etc/passwd, not HOME, so a host UID that the image does define (such + as 1000, its "ubuntu" user) would otherwise publish into the container. """ if native: cwd = workdir @@ -351,6 +354,7 @@ def _run_java_sdk_gradle(workdir, *gradle_argv, capture_output=False, native=Fal "eclipse-temurin:17-jdk", "/repo/java-sdk/gradlew", "--no-daemon", + "-Dmaven.repo.local=/workspace-home/.m2/repository", *gradle_argv, ] return subprocess.run(argv, cwd=cwd, check=True, capture_output=capture_output, text=True)
