You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Running ./mvnw spring-boot:build-image fails with the following exception:
Caused by: java.lang.NullPointerException
at org.springframework.boot.buildpack.platform.docker.type.ImageConfig.parseConfigEnv (ImageConfig.java:52)
at org.springframework.boot.buildpack.platform.docker.type.ImageConfig.<init> (ImageConfig.java:46)
at org.springframework.boot.buildpack.platform.docker.type.Image.<init> (Image.java:51)
at org.springframework.boot.buildpack.platform.json.MappedObject.of (MappedObject.java:148)
at org.springframework.boot.buildpack.platform.json.MappedObject.of (MappedObject.java:131)
at org.springframework.boot.buildpack.platform.docker.type.Image.of (Image.java:111)
at org.springframework.boot.buildpack.platform.docker.DockerApi$ImageApi.pull (DockerApi.java:163)
at org.springframework.boot.buildpack.platform.build.Builder.pullBuilder (Builder.java:85)
at org.springframework.boot.buildpack.platform.build.Builder.build (Builder.java:63)
at org.springframework.boot.maven.BuildImageMojo.buildImage (BuildImageMojo.java:136)
at org.springframework.boot.maven.BuildImageMojo.execute (BuildImageMojo.java:128)
Thanks for the sample, @jcfandino. The cause of the problem is that you are specifying gcr.io/paketo-buildpacks/bellsoft-liberica as a builder when it is an individual buildpack. As a result, the JSON that describes the image does not contain some information that is expected to be there. We don't handle this gracefully which results in the NPE. We need to improve the error handling here.
wilkinsona
changed the title
NPE in spring-boot-maven-plugin:build-image when setting custom builder
NPE in spring-boot-maven-plugin:build-image when setting custom builder that is not a builder
Jul 1, 2020
When I try to set a custom builder in the maven plugin by following the documentation:
https://docs.spring.io/spring-boot/docs/current/maven-plugin/reference/html/#build-image-example-custom-image-builder
Like this:
Running
./mvnw spring-boot:build-image
fails with the following exception:I made this project to reproduce the error: https://github.com/jcfandino/spring-boot-npe
You can look at the build pipeline to see the error: https://github.com/jcfandino/spring-boot-npe/actions
The text was updated successfully, but these errors were encountered: