Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fail on bootBuildImage with launch script
This commit adds a check to the support code for the Gradle plugin bootBuildImage task to ensure that the jar file that will be passed to a builder is readable and has a valid directory. This prevents a situation where the jar file cannot be read because it is prepended with a launch script, and the builder does not receive any files to process. Notes have also been added to the Gradle plugin documentation to warn against using a bootJar launchScript configuration and bootBuildImage together, as well as caveats about launchScript that match the Maven plugin documentation. Fixes gh-22223
- Loading branch information
1 parent
259ea65
commit 2102822
Showing
6 changed files
with
38 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
11 changes: 11 additions & 0 deletions
11
...rk/boot/gradle/tasks/bundling/BootBuildImageIntegrationTests-failsWithLaunchScript.gradle
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
plugins { | ||
id 'java' | ||
id 'org.springframework.boot' version '{version}' | ||
} | ||
|
||
sourceCompatibility = '1.8' | ||
targetCompatibility = '1.8' | ||
|
||
bootJar { | ||
launchScript() | ||
} |