From eb03900f3298b272985022336c7810f838d5205b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Deleuze?= Date: Fri, 28 Aug 2020 18:16:54 +0200 Subject: [PATCH] Document workaround for spring-projects/spring-boot#23130 --- .../src/main/asciidoc/troubleshooting.adoc | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/spring-graalvm-native-docs/src/main/asciidoc/troubleshooting.adoc b/spring-graalvm-native-docs/src/main/asciidoc/troubleshooting.adoc index 6d221507a..08dc8d223 100644 --- a/spring-graalvm-native-docs/src/main/asciidoc/troubleshooting.adoc +++ b/spring-graalvm-native-docs/src/main/asciidoc/troubleshooting.adoc @@ -26,6 +26,25 @@ The image can fail for a number of reasons. We have described the most common ca If your built image does not run, you can try a number of fixes. This section describes those possible fixes. +=== Spring Boot image building fails when specifying + +With some content specified in between `` element in Spring Boot image configuration, +the build can fail with an error like: + +==== +[source,bash] +---- +[ERROR] Failed to execute goal org.springframework.boot:spring-boot-maven-plugin:2.4.0-M2:build-image (default-cli) on project rest-service: +Execution default-cli of goal org.springframework.boot:spring-boot-maven-plugin:2.4.0-M2:build-image failed: Docker API call to +'localhost/v1.24/images/pack.local/builder/otmkahcvlf:latest?force=1' failed with status code 404 "Not Found" +---- +==== + +This is due to https://github.com/spring-projects/spring-boot/issues/23130[this bug] that will be fixed asap. +The workaround is to try to modify the content (change space to tabs, add or remove line breaks, etc.) to not hit that bug or +to replace `` element by a `META-INF/native-image///native-image.properties` +file with `Args = ...` content. + ==== Missing resource bundles In some cases, when there is a problem, the error message tries to tell you exactly what to do, as follows: