question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Builder lifecycle 'creator' failed with status code 20

See original GitHub issue

Execute

 ./gradlew bootBuildImage 

Build Dependencies

classpath
+--- org.springframework.boot:spring-boot-gradle-plugin:3.0.0-RC1
|    +--- org.springframework.boot:spring-boot-buildpack-platform:3.0.0-RC1
|    |    +--- com.fasterxml.jackson.core:jackson-databind:2.14.0-rc2
|    |    |    +--- com.fasterxml.jackson.core:jackson-annotations:2.14.0-rc2
|    |    |    |    \--- com.fasterxml.jackson:jackson-bom:2.14.0-rc2
|    |    |    |         +--- com.fasterxml.jackson.core:jackson-annotations:2.14.0-rc2 (c)
|    |    |    |         +--- com.fasterxml.jackson.core:jackson-core:2.14.0-rc2 (c)
|    |    |    |         +--- com.fasterxml.jackson.core:jackson-databind:2.14.0-rc2 (c)
|    |    |    |         +--- com.fasterxml.jackson.datatype:jackson-datatype-jsr310:2.14.0-rc2 (c)
|    |    |    |         \--- com.fasterxml.jackson.module:jackson-module-parameter-names:2.14.0-rc2 (c)
|    |    |    +--- com.fasterxml.jackson.core:jackson-core:2.14.0-rc2
|    |    |    |    \--- com.fasterxml.jackson:jackson-bom:2.14.0-rc2 (*)
|    |    |    \--- com.fasterxml.jackson:jackson-bom:2.14.0-rc2 (*)
|    |    +--- com.fasterxml.jackson.module:jackson-module-parameter-names:2.14.0-rc2
|    |    |    +--- com.fasterxml.jackson.core:jackson-core:2.14.0-rc2 (*)
|    |    |    +--- com.fasterxml.jackson.core:jackson-databind:2.14.0-rc2 (*)
|    |    |    \--- com.fasterxml.jackson:jackson-bom:2.14.0-rc2 (*)
|    |    +--- net.java.dev.jna:jna-platform:5.7.0
|    |    |    \--- net.java.dev.jna:jna:5.7.0
|    |    +--- org.apache.commons:commons-compress:1.21
|    |    +--- org.apache.httpcomponents:httpclient:4.5.13
|    |    |    +--- org.apache.httpcomponents:httpcore:4.4.13 -> 4.4.14
|    |    |    +--- commons-logging:commons-logging:1.2
|    |    |    \--- commons-codec:commons-codec:1.11
|    |    +--- org.springframework:spring-core:6.0.0-RC2
|    |    |    \--- org.springframework:spring-jcl:6.0.0-RC2
|    |    \--- org.tomlj:tomlj:1.0.0
|    |         +--- org.antlr:antlr4-runtime:4.7.2
|    |         \--- com.google.code.findbugs:jsr305:3.0.2
|    +--- org.springframework.boot:spring-boot-loader-tools:3.0.0-RC1
|    |    +--- org.apache.commons:commons-compress:1.21
|    |    \--- org.springframework:spring-core:6.0.0-RC2 (*)
|    +--- io.spring.gradle:dependency-management-plugin:1.1.0
|    +--- org.apache.commons:commons-compress:1.21
|    \--- org.springframework:spring-core:6.0.0-RC2 (*)
+--- io.spring.gradle:dependency-management-plugin:1.1.0
+--- net.ltgt.errorprone:net.ltgt.errorprone.gradle.plugin:1.1.1
|    \--- net.ltgt.gradle:gradle-errorprone-plugin:1.1.1
+--- org.hidetake.ssh:org.hidetake.ssh.gradle.plugin:2.10.1
|    \--- org.hidetake:gradle-ssh-plugin:2.10.1
|         \--- org.hidetake:groovy-ssh:2.10.1
|              +--- org.slf4j:slf4j-api:1.7.7
|              +--- com.jcraft:jsch:0.1.55
|              +--- com.jcraft:jsch.agentproxy.connector-factory:0.0.9
|              |    +--- com.jcraft:jsch.agentproxy.core:0.0.9
|              |    +--- com.jcraft:jsch.agentproxy.usocket-jna:0.0.9
|              |    |    +--- com.jcraft:jsch.agentproxy.core:0.0.9
|              |    |    +--- net.java.dev.jna:jna:4.1.0 -> 5.7.0
|              |    |    \--- net.java.dev.jna:jna-platform:4.1.0 -> 5.7.0 (*)
|              |    +--- com.jcraft:jsch.agentproxy.usocket-nc:0.0.9
|              |    |    \--- com.jcraft:jsch.agentproxy.core:0.0.9
|              |    +--- com.jcraft:jsch.agentproxy.sshagent:0.0.9
|              |    |    \--- com.jcraft:jsch.agentproxy.core:0.0.9
|              |    \--- com.jcraft:jsch.agentproxy.pageant:0.0.9
|              |         +--- com.jcraft:jsch.agentproxy.core:0.0.9
|              |         +--- net.java.dev.jna:jna:4.1.0 -> 5.7.0
|              |         \--- net.java.dev.jna:jna-platform:4.1.0 -> 5.7.0 (*)
|              \--- com.jcraft:jsch.agentproxy.jsch:0.0.9
|                   +--- com.jcraft:jsch:0.1.49 -> 0.1.55
|                   \--- com.jcraft:jsch.agentproxy.core:0.0.9
+--- com.google.cloud.tools.jib:com.google.cloud.tools.jib.gradle.plugin:3.1.1
|    \--- gradle.plugin.com.google.cloud.tools:jib-gradle-plugin:3.1.1
|         +--- com.google.http-client:google-http-client:1.38.1
|         |    +--- org.apache.httpcomponents:httpclient:4.5.13 (*)
|         |    +--- org.apache.httpcomponents:httpcore:4.4.14
|         |    +--- com.google.code.findbugs:jsr305:3.0.2
|         |    +--- com.google.guava:guava:30.1-android -> 30.1.1-jre
|         |    |    +--- com.google.guava:failureaccess:1.0.1
|         |    |    +--- com.google.guava:listenablefuture:9999.0-empty-to-avoid-conflict-with-guava
|         |    |    +--- com.google.code.findbugs:jsr305:3.0.2
|         |    |    +--- org.checkerframework:checker-qual:3.8.0
|         |    |    +--- com.google.errorprone:error_prone_annotations:2.5.1
|         |    |    \--- com.google.j2objc:j2objc-annotations:1.3
|         |    +--- com.google.j2objc:j2objc-annotations:1.3
|         |    +--- io.opencensus:opencensus-api:0.24.0
|         |    |    \--- io.grpc:grpc-context:1.22.1
|         |    \--- io.opencensus:opencensus-contrib-http-util:0.24.0
|         |         +--- io.opencensus:opencensus-api:0.24.0 (*)
|         |         \--- com.google.guava:guava:26.0-android -> 30.1.1-jre (*)
|         +--- com.google.http-client:google-http-client-apache-v2:1.38.1
|         |    +--- com.google.http-client:google-http-client:1.38.1 (*)
|         |    +--- org.apache.httpcomponents:httpclient:4.5.13 (*)
|         |    \--- org.apache.httpcomponents:httpcore:4.4.14
|         +--- com.google.auth:google-auth-library-oauth2-http:0.22.2
|         |    +--- com.google.auto.value:auto-value-annotations:1.7.4
|         |    +--- com.google.code.findbugs:jsr305:3.0.2
|         |    +--- com.google.auth:google-auth-library-credentials:0.22.2
|         |    +--- com.google.http-client:google-http-client:1.38.0 -> 1.38.1 (*)
|         |    +--- com.google.http-client:google-http-client-jackson2:1.38.0
|         |    |    +--- com.google.http-client:google-http-client:1.38.0 -> 1.38.1 (*)
|         |    |    \--- com.fasterxml.jackson.core:jackson-core:2.11.3 -> 2.14.0-rc2 (*)
|         |    \--- com.google.guava:guava:30.0-android -> 30.1.1-jre (*)
|         +--- org.apache.commons:commons-compress:1.20 -> 1.21
|         +--- com.google.guava:guava:30.1.1-jre (*)
|         +--- com.fasterxml.jackson.core:jackson-databind:2.12.3 -> 2.14.0-rc2 (*)
|         +--- com.fasterxml.jackson.datatype:jackson-datatype-jsr310:2.12.3 -> 2.14.0-rc2
|         |    +--- com.fasterxml.jackson.core:jackson-annotations:2.14.0-rc2 (*)
|         |    +--- com.fasterxml.jackson.core:jackson-core:2.14.0-rc2 (*)
|         |    +--- com.fasterxml.jackson.core:jackson-databind:2.14.0-rc2 (*)
|         |    \--- com.fasterxml.jackson:jackson-bom:2.14.0-rc2 (*)
|         +--- org.ow2.asm:asm:9.1
|         +--- com.google.cloud.tools:jib-build-plan:0.4.0
|         +--- com.google.cloud.tools:jib-plugins-extension-common:0.2.0
|         \--- com.google.cloud.tools:jib-gradle-plugin-extension-api:0.4.0
|              +--- com.google.cloud.tools:jib-build-plan:0.4.0
|              \--- com.google.cloud.tools:jib-plugins-extension-common:0.2.0
\--- org.graalvm.buildtools.native:org.graalvm.buildtools.native.gradle.plugin:0.9.16
     \--- org.graalvm.buildtools:native-gradle-plugin:0.9.16
          +--- org.graalvm.buildtools:utils:0.9.16
          |    \--- com.fasterxml.jackson.core:jackson-databind:2.13.3 -> 2.14.0-rc2 (*)
          \--- org.graalvm.buildtools:graalvm-reachability-metadata:0.9.16
               \--- com.fasterxml.jackson.core:jackson-databind:2.13.3 -> 2.14.0-rc2 (*)

Error

> Task :flycat-price:bootBuildImage
Building image 'docker.io/library/flycat-price:local-git_main_20221029_211328_82f596a'

 > Pulling builder image 'docker.io/paketobuildpacks/builder:tiny' ..................................................
 > Pulled builder image 'paketobuildpacks/builder@sha256:b8e058067cd45470f2ae4e02d44c410105601a8b3b5a9f85d5274bc8330c99a9'
 > Pulling run image 'docker.io/paketobuildpacks/run:tiny-cnb' ..................................................
 > Pulled run image 'paketobuildpacks/run@sha256:eb543f618cbae8f0c32c7ab11284cc4f3074f5275902f17ece9def661e9b5c50'
 > Executing lifecycle version v0.14.3
 > Using build cache volume 'pack-cache-8dfe90627122.build'

 > Running creator
    [creator]     Previous image with name "docker.io/library/flycat-price:local-git_main_20221029_211328_82f596a" not found
    [creator]     ===> DETECTING
    [creator]     ERROR: No buildpack groups passed detection.
    [creator]     ERROR: Please check that you are running against the correct path.
    [creator]     ERROR: failed to detect: no buildpacks participating

> Task :flycat-price:bootBuildImage FAILED

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':flycat-price:bootBuildImage'.
> Builder lifecycle 'creator' failed with status code 20

Version

❯ uname -a
Darwin MacBook-Air 21.6.0 Darwin Kernel Version 21.6.0: Mon Aug 22 20:20:07 PDT 2022; root:xnu-8020.140.49~2/RELEASE_ARM64_T8110 arm64

❯ java --version
openjdk 17.0.4 2022-07-19 LTS
OpenJDK Runtime Environment GraalVM 22.2.0 (build 17.0.4+8-LTS)
OpenJDK 64-Bit Server VM GraalVM 22.2.0 (build 17.0.4+8-LTS, mixed mode, sharing)

~/Dropbox/Project/flycat-projects main*
❯ ./gradlew --version

------------------------------------------------------------
Gradle 7.5.1
------------------------------------------------------------

Build time:   2022-08-05 21:17:56 UTC
Revision:     d1daa0cbf1a0103000b71484e1dbfe096e095918

Kotlin:       1.6.21
Groovy:       3.0.10
Ant:          Apache Ant(TM) version 1.10.11 compiled on July 10 2021
JVM:          17.0.4 (BellSoft 17.0.4+8-LTS)
OS:           Mac OS X 12.6 aarch64


Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:10 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
scottfrederickcommented, Nov 3, 2022

how to build the Docker image for a non native build?

Remove the <buildpacks></buildpacks> configuration from pom.xml and allow the default buildpacks to be used. You’re explicitly configuring the image build to use the java-native-image buildpack, which you don’t want to do if you want an image that runs the jar in a JVM.

Configuring the buildpacks to use when you want a native image, as in these examples, is a short-term work-around that will not be required by the time Spring Framework 6.0 and Spring Boot 3.0 are released. At that time, the correct buildpacks will be chosen based on whether you’re building with a native profile or not without any explicit <buildpacks> configuration.

This discussions is straying away from the original issue now. If you have further questions, please post them to StackOverflow.

0reactions
jabrenacommented, Nov 4, 2022

Hi @scottfrederick,

I share with the community a way to build docker images with JVM inside and Native one:

	<profiles>
		<profile>
			<id>jvm</id>
			<activation>
				<activeByDefault>true</activeByDefault>
			</activation>
			<build>
				<plugins>
					<plugin>
						<groupId>org.springframework.boot</groupId>
						<artifactId>spring-boot-maven-plugin</artifactId>
						<configuration>
							<imageName>my-demo:buildpacks-jvm.0.0.1-SNAPSHOT</imageName>
							<image>
								<buildpacks>
									<!-- EMPTY -->
								</buildpacks>
							</image>
						</configuration>
					</plugin>
				</plugins>
			</build>
		</profile>
		<profile>
			<id>native</id>
			<build>
				<plugins>
					<plugin>
						<groupId>org.springframework.boot</groupId>
						<artifactId>spring-boot-maven-plugin</artifactId>
						<configuration>
							<imageName>my-demo:buildpacks-native.0.0.1-SNAPSHOT</imageName>
							<image>
								<buildpacks>
									<buildpack>gcr.io/paketo-buildpacks/bellsoft-liberica:9.10</buildpack>
									<buildpack>gcr.io/paketo-buildpacks/java-native-image</buildpack>
								</buildpacks>
							</image>
						</configuration>
					</plugin>
				</plugins>
			</build>
		</profile>
	</profiles>
echo "Generated Executables with buildpacks"
mvn -Pnative spring-boot:build-image
mvn spring-boot:build-image
Read more comments on GitHub >

github_iconTop Results From Across the Web

Why do I have ' Builder lifecycle 'creator' failed with status ...
I'm learning Docker and I'm trying to create an Image of my current Spring project. I'm trying to run mvn spring-boot:build-image to create...
Read more >
mvn spring-boot:build-image failed: Builder lifecycle 'creator ...
I am using Spring Boot 2.3.1 version. While executing the maven command mvn spring-boot:build-image. I am getting the below error . Failed to ......
Read more >
Spring-Boot native image Build fails with status c...
Hi, I'm trying to build a simple Spring Boot Demo Project as a Spring Native Image and run into this error ... [INFO]...
Read more >
Trusted Builders - Cloud Native Buildpacks
When pack considers a builder to be trusted, pack build operations will use a single lifecycle binary called the creator . If pack...
Read more >
How to build cloud-ready images with Cloud Native Buildpacks.
A builder image consists of a build image, lifecycle, buildpacks and ... This may be the result of using an untrusted builder: failed...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found