-
-
Notifications
You must be signed in to change notification settings - Fork 56
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
ERROR: JAVA_HOME is set to an invalid directory: /opt/java/openjdk #11
Comments
Hi @dellisd, I will take a look tomorrow. Meanwhile use the previous tag |
Hi @dellisd, I was not able to reproduce it on my machine building skydoves/Pokedex. It seems to be working using the latest version. Could you try again running the same command or another, like This is also weird because the only change between versions is the Android 31 SDK. |
Unfortunately the project isn't public so there isn't much I can share there, however I did run a build on a separate project that is open source, but the build worked normally. Both the Reverting to the previous tag did resolve the issue, so it does seem related to the latest image but I can't think of any reason why, especially as you say the only difference was the version of the SDK. This is running in a Bitbucket Pipeline, so perhaps that's related. |
Like @dellisd said, even my CI pipeline failed with the same error. Reverting to previous tag resolved the issue. |
Hi @dellisd, @nayaksushma, @darekxan. Tomorrow I will create a test image using Liberica JDK instead of AdoptOpenJDK because of #10. I will let you know when it is ready so you can test this version. |
Hi, I have the same error using: |
That must be because you have a JAVA_HOME environment variable set to jdk11 already or you have configured your AS to use jdk11. |
I published a new version for AdoptOpenJDK Thanks. |
Gave the two new images a try today. The AdoptOpenJDK one failed with the same error, but the Liberica one ran normally. |
So did you find why this message appears ? It come from the Gradle wrapper which doesn't find java binary. But it appears only on CI, not on my local machine. |
As a workaround, I set the JAVA_HOME to "". The Gradle wrapper does no more fails with the invalid directory : /opt/java/openjdk. |
Hi @dellisd, @nayaksushma, @20100, @daviCalavera, @edwnmrtnz. The release v2021.10.22 now uses Liberica as base image. If the issues persists with this version, please, reopen the issue. |
I'm still experiencing this issue with image: After adding Nevertheless I was able to get my build to work by using this older android-31 image: |
The CI I have set up that uses this docker image suddenly stopped working and it appears to be related to the newest release.
This was using
alvrme/alpine-android:android-30-jdk11
:The text was updated successfully, but these errors were encountered: