Skip to content

Commit

Permalink
Add documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
keeganwitt committed Apr 6, 2024
1 parent 9a58a0a commit 169d595
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,25 @@
* [jdk-lts-and-current-alpine](https://github.com/keeganwitt/docker-gradle/blob/master/jdk-lts-and-current-alpine/Dockerfile)
* [jdk-lts-and-current-graal](https://github.com/keeganwitt/docker-gradle/blob/master/jdk-lts-and-current-graal/Dockerfile)

### lts-and-current images

Gradle's support for new Java releases historically has lagged for multiple months.
This means most users wanting to use the latest Java release will need to do so using toolchains.
Toolchains are
documented [here](https://docs.gradle.org/current/userguide/toolchains.html) and [here](https://graalvm.github.io/native-build-tools/latest/gradle-plugin.html#configuration-toolchains) for GraalVM.
The lts-and-current images provide both the latest LTS JDK and the latest (LTS or non-LTS) JDK.
This allows Gradle to be launched with a supported JDK (the latest LTS release)
and configure the compilation using toolchains to use the latest current JDK.
This is done by putting the content below in `/home/gradle/.gradle/gradle.properties`.
```properties
org.gradle.java.installations.auto-detect=false
org.gradle.java.installations.auto-download=false
org.gradle.java.installations.fromEnv=JAVA_LTS_HOME,JAVA_CURRENT_HOME
```
The `JAVA_LTS_HOME` environment variable points to the path
where the latest LTS JDK is installed and `JAVA_CURRENT_HOME` points to the latest current JDK.
These may point to the same path if the latest JDK is an LTS release.

## What is Gradle?

[Gradle](https://gradle.org/) is a build tool with a focus on build automation and support for multi-language development. If you are building, testing, publishing, and deploying software on any platform, Gradle offers a flexible model that can support the entire development lifecycle from compiling and packaging code to publishing websites. Gradle has been designed to support build automation across multiple languages and platforms including Java, Scala, Android, C/C++, and Groovy, and is closely integrated with development tools and continuous integration servers including Eclipse, IntelliJ, and Jenkins.
Expand Down

0 comments on commit 169d595

Please sign in to comment.