-
Notifications
You must be signed in to change notification settings - Fork 21
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
Set JAVA_HOME
and JDK_HOME
as defaults, not overrides
#185
Comments
@dmikusa What about this? If you agree that libjvm should follow the spec here, we can have a look and provide a PR. |
This came up previously and I don't think we should follow the spec for these particular variables. My opinion is that a user should not set these values ever, the buildpack should always set them so I think If there is a legitimate use case for setting them, I'd be OK with making the change. I just can't think of a reason. The buildpack is the only thing that will know where the JVM is installed, so it should be setting these. Even in the case where the JVM is installed as part of the stack, or by a buildpack extension, I think that the buildpack should run, pull out the location of the JVM, and set these env variables. Presently, you can't set env variables if you only publish a stack so the buildpack would still be required to get the env variables set in a consistent way. |
Hi @dmikusa, Best |
OK. I'm going to mark this as If someone comes up with a legitimate reason that requires |
In Paketo RFC 0019, the project set the norm that
"Language ecosystem environment variables" are those that are respected by language ecosystem tooling, like the Java toolchain.
JAVA_HOME
andJDK_HOME
are two of these sort of variables.Currently, libjvm sets these environment variables using the OVERRIDE option.
I propose that these environment variables should be set with the DEFAULT option instead, to bring libjvm in alignment with the RFC. This should not change buildpack behaviour in the happy-path case. But it will allow advanced users to override the buildpack's default
JAVA_HOME
andJDK_HOME
values at build- or launch-timeThe text was updated successfully, but these errors were encountered: