Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dependency Graph submission init script hard codes the "" URL #933

yogurtearl opened this issue Oct 10, 2023 · 4 comments
enhancement New feature or request


Copy link

The init script adds this URL with might not be accessible: ""

I am requesting a way to configure that repo URL.

For example, if I have an internal proxy called that proxies, I need a way to configure that.

Also, this could pollute the buildscript repos for other plugins, so it should use exclusiveContent to limit the scope.

Instead, would be good to have something like:

    exclusiveContent {
        forRepository {
                ?.let { maven(it) }
                ?: gradlePluginPortal()
        filter {
            includeModule("org.gradle.github-dependency-graph-gradle-plugin", "org.gradle.github-dependency-graph-gradle-plugin.gradle.plugin")
Copy link

jb-2020 commented Nov 13, 2023

Also bumping into this one, would be great to support more enterprise use cases. I've forked this action with the following:

  repositories {
    maven { 
      url "<private gradle plugin repository>
      credentials {
        username = System.getenv("USERNAME")
        password = System.getenv("PASSWORD")

Unclear if it's user error but I also had trouble configuring the maven credentials. Assuming this is because this is an init script? Using env vars rather than gradle properties seems to be a work around.

@bigdaz bigdaz self-assigned this Dec 12, 2023
@bigdaz bigdaz added the enhancement New feature or request label Dec 12, 2023
@bigdaz bigdaz added this to the 2.11.0 milestone Dec 12, 2023
@bigdaz bigdaz closed this as completed in 8cbcb99 Dec 12, 2023
Copy link

jb-2020 commented Dec 12, 2023

@bigdaz thanks for the fix, but there may be scenarios where users need maven credentials for this URL. Any suggestions?

Copy link

bigdaz commented Dec 13, 2023

@bigdaz thanks for the fix, but there may be scenarios where users need maven credentials for this URL. Any suggestions?

No. We have provided similar functionality with all of our Develocity CI integrations, and while PLUGIN_REPOSITORY_URL is part of each, nobody has asked for authentication.

Can you please raise a separate issue for this, with your specific use case?

Copy link

bigdaz commented Dec 20, 2023

@yogurtearl I considered adding the exclusiveContent restriction, but from my understanding the buildscript block only applies to the current script, which is applied from an init-script, and won't impact dependency resolution in other scripts.

Have you seen evidence of this sort of repository leakage?

bigdaz added a commit that referenced this issue Dec 23, 2023
The repository URL used to resolve the `github-dependency-graph-gradle-plugin` is now
configurable, allowing a user to specify an internal proxy if the public portal is not available.

Specify a custom plugin repository using the `GRADLE_PLUGIN_REPOSITORY_URL` env var,
or the `gradle.plugin-repository.url` System property.

Fixes #933
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
enhancement New feature or request
None yet

No branches or pull requests

3 participants