From 4ebc1ed2fae629fd2f32d52232f8dfc696b73cf7 Mon Sep 17 00:00:00 2001 From: Brice Dutheil Date: Mon, 21 Sep 2026 16:45:08 +0200 Subject: [PATCH 1/2] ci: route exploration Maven builds through repository proxy --- .gitlab/exploration-tests.yml | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/.gitlab/exploration-tests.yml b/.gitlab/exploration-tests.yml index be3a36c384d..0e290ab8c54 100644 --- a/.gitlab/exploration-tests.yml +++ b/.gitlab/exploration-tests.yml @@ -34,6 +34,20 @@ build-exploration-tests-image: - when: manual allow_failure: true before_script: + - | + mkdir -p "$HOME/.m2" + cat > "$HOME/.m2/settings.xml" < + + + env-proxy + * + ${MAVEN_REPOSITORY_PROXY} + + + + EOF + - export MVNW_REPOURL=${MAVEN_REPOSITORY_PROXY%/} - cp workspace/dd-java-agent/build/libs/*.jar /exploration-tests/dd-java-agent.jar - cp dd-java-agent/agent-debugger/exploration-tests/run-exploration-tests.sh /exploration-tests - cp dd-java-agent/agent-debugger/exploration-tests/exclude_*.txt /exploration-tests From b14d757ea687bae0da10b6e7fb84e03de5205dc1 Mon Sep 17 00:00:00 2001 From: Brice Dutheil Date: Tue, 22 Sep 2026 11:10:32 +0200 Subject: [PATCH 2/2] ci: proxy Gradle exploration repositories --- .gitlab/exploration-tests.yml | 5 +++++ .../buildlogic/smoketest/proxy-repositories.init.gradle.kts | 2 ++ 2 files changed, 7 insertions(+) diff --git a/.gitlab/exploration-tests.yml b/.gitlab/exploration-tests.yml index 0e290ab8c54..f8d39acbbbb 100644 --- a/.gitlab/exploration-tests.yml +++ b/.gitlab/exploration-tests.yml @@ -48,6 +48,11 @@ build-exploration-tests-image: EOF - export MVNW_REPOURL=${MAVEN_REPOSITORY_PROXY%/} + - export ORG_GRADLE_PROJECT_mavenRepositoryProxy="$MAVEN_REPOSITORY_PROXY" + - export ORG_GRADLE_PROJECT_gradlePluginProxy="$GRADLE_PLUGIN_PROXY" + # TODO: Centralize Gradle repository proxy initialization instead of reusing a smoke-test resource. + - mkdir -p "$HOME/.gradle/init.d" + - cp build-logic/smoke-test/src/main/resources/datadog/buildlogic/smoketest/proxy-repositories.init.gradle.kts "$HOME/.gradle/init.d/" - cp workspace/dd-java-agent/build/libs/*.jar /exploration-tests/dd-java-agent.jar - cp dd-java-agent/agent-debugger/exploration-tests/run-exploration-tests.sh /exploration-tests - cp dd-java-agent/agent-debugger/exploration-tests/exclude_*.txt /exploration-tests diff --git a/build-logic/smoke-test/src/main/resources/datadog/buildlogic/smoketest/proxy-repositories.init.gradle.kts b/build-logic/smoke-test/src/main/resources/datadog/buildlogic/smoketest/proxy-repositories.init.gradle.kts index 53d998e203c..4d059fd9645 100644 --- a/build-logic/smoke-test/src/main/resources/datadog/buildlogic/smoketest/proxy-repositories.init.gradle.kts +++ b/build-logic/smoke-test/src/main/resources/datadog/buildlogic/smoketest/proxy-repositories.init.gradle.kts @@ -5,6 +5,8 @@ import org.gradle.api.artifacts.repositories.MavenArtifactRepository import org.gradle.api.initialization.Settings import java.net.URI +// Requires Gradle 6.8+ and assumes project repositories are allowed by the target build. + gradle.beforeSettings(Action { val gradlePluginProxy = providers.gradleProperty("gradlePluginProxy").orNull val mavenRepositoryProxy = providers.gradleProperty("mavenRepositoryProxy").orNull