gradle-trust-all
gradle-trust-all copied to clipboard
trust-all plugin not found
Hi,
I follow the instructions and gradle failed with "trust-all plugin not found" error
Any idea?
What version of gradle are you using? The project I use the plugin in is using quite an old version of gradle (2.2), so there might be a chance it is incompatible with newer versions. I'll check...
With 2.8,2.11&2.12..
Currently with 2.12
Thanks
Works here with gradle 2.12:
$ tree
.
├── build.gradle
├── gradle
│ ├── gradle-trust-all.jar
│ └── wrapper
│ ├── gradle-wrapper.jar
│ └── gradle-wrapper.properties
├── gradlew
├── gradlew.bat
└── settings.gradle
$ cat build.gradle
buildscript {
dependencies {
classpath files('gradle/gradle-trust-all.jar')
}
}
apply plugin: 'trust-all'
$ gradle
:help
Welcome to Gradle 2.12.
To run a build, run gradle <task> ...
To see a list of available tasks, run gradle tasks
To see a list of command-line options, run gradle --help
To see more detail about a task, run gradle help --task <task>
BUILD SUCCESSFUL
Total time: 2.309 secs
This build could be faster, please consider using the Gradle Daemon: https://docs.gradle.org/2.12/userguide/gradle_daemon.html
If I remove "gradle-trust-all.jar" JAR file, then gradle complains.
Of course, if you reference the JAR from a subproject, you might want to make that path relative to the root project (files("$rootProject.projectDir/gradle/gradle-trust-all.jar")
), but as far as I understand it, it should be enough to place the buildscript { ... }
block in the root project build.gradle file, then apply plugin: 'trust-all'
works for subprojects build.gradle files...
OK, Now it it found.. But the library doesn't work :(...
Same error: FAILURE: Build failed with an exception.
-
What went wrong: A problem occurred configuring project ':app'.
Could not resolve all dependencies for configuration ':app:_debugCompile'. Could not resolve com.github.renaudcerrato:FloatingSearchView:1.0.0. Required by: CashBackApp:app:unspecified Could not resolve com.github.renaudcerrato:FloatingSearchView:1.0.0. > Could not get resource 'https://jitpack.io/com/github/renaudcerrato/FloatingSearchView/1.0.0/FloatingSearchView-1.0.0.pom'. > Could not GET 'https://jitpack.io/com/github/renaudcerrato/FloatingSearchView/1.0.0/FloatingSearchView-1.0.0.pom'. > sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
-
Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
BUILD FAILED
Total time: 7.092 secs
Weird. Using jitpack.io shouldn't require trust-all plugin at all.
Any idea?.... BTW, I'm working on Windows.
Even that shouldn't stop you. You may want to verify your default java keystore is okay using SSLPoke from https://confluence.atlassian.com/kb/unable-to-connect-to-ssl-services-due-to-pkix-path-building-failed-779355358.html like:
$ java SSLPoke jitpack.io 443
Successfully connected
However, this problem may arise if you're using a custom keystore in your project. If you have something like this in your gradle.properties
file:
systemProp.javax.net.ssl.trustStore=...
systemProp.javax.net.ssl.trustStorePassword=...
Then gradle will expect to be able to use that keystore to validate all SSL connections. Then that should be a copy of your default java keystore (such as c:\Program Files\Java\jre7\lib\security\cacerts
) with all the extra certificates you need added using an appropriate tool (like keytool
).
And indeed, in this situation I see the same error as you do, so we can assume the plug-in is indeed not working :( at least with new gradle versions. I'll need to debug this more.
Hi,
Actually, when I run "java SSLPoke jitpack.io 443" in my windows I get this error..
Java was update today..
How can I add jitpack.io certificate.?
I tried it before..but seems it didn't success