Closed derkoe closed 7 months ago
Sounds like Jib needs to fix this to support newer Docker versions. In that case, #4172 should do it.
@derkoe @chanseokoh Thanks for starting this discussion! To better understand the issue, it looks like Jib is return an error when the manifest contains the LayerSources
field. I'm curious about where this extra field is coming from. Does this happen regardless of which base image you use? Additionally, I wasn't able to find references to it in the official docs but perhaps you may more context for this.
@mpeddada1 I have no context about this. Just guessing from @derkoe's comments, the latest Docker may have this field, at least in some cases. But I thought it wouldn't hurt to allow extra fields anyway. @derkoe should answer these.
@mpeddada1 it happens with any image I've tried so far.
Thank you both for the follow-up. Hm @derkoe that is interesting. Are Docker 25 built images always including this field in the manifest now?
I am not talking about images built with Docker 25 - the image format did not change. I am talking about using a Docker installation in version 25 where Jib get's the image from the daemon <image>docker://any-image</image>
I am talking about using a Docker installation in version 25 where Jib get's the image from the daemon
<image>docker://any-image</image>
I see, thanks for the clarification.
A follow-up q: do you run into the same issue when using the default base image? Specifically when you don't specify <from><image>docker://any-image</image></from>
. Or when pulling in a base image from a container registry like this:
<configuration>
<from><image>gcr.io/{REPO}/{NAME}:{TAG}</image></from>
</configuration>
@mpeddada1
A follow-up q: do you run into the same issue when using the default base image?
I am using the default base image in my example above: eclipse-temurin:8-jre
Specifically when you don't specify
. Or when pulling in a base image from a container registry like this. docker://any-image
The error only occurs when you specifiy the image from with the "docker://" prefix - this is exactly my bug description. It works if you do not specifiy the image.
Again: this error only occurs when the Docker image is loaded from the local Docker daemon with version >= 25. (using the docker://
prefix in the image from).
Today I ran into the same problem.
As a workaround I tried to create a tar with docker first by using docker save
and then using tar://
as prefix in the image from, but this resulted in them same problem.
So the tar prefix is affected as well, if the tar was created with daemon version >= 25
Since this day, bitbucket uses version 25 of docker in the pipelines. As a result, all my builds fail. I have no idea of an alternative solution to counter this big problem from my point of view.
Is there a timeline to release the fix in the near future? My Bitbucket pipelines currently don't work since Bitbucket cloud forces Docker v25. I could build the Docker image myself, but I would prefer to keep using jib...
Is there a plan to release it? It is currently breaking our builds too.
hey any due date for the fix release as i see it is fixed in https://github.com/GoogleContainerTools/jib/pull/4172 ?
jib-core:0.26.0, jib-maven-plugin:3.4.1 and jib-gradle-plugin:3.4.1 have been released with this fix. Thanks for reporting @derkoe and thanks for making the fix @chanseokoh!
Environment:
Description of the issue: Jib error on Docker 25.0.0. with
<from><image>docker://eclipse-temurin:8-jre</image></from>
:Expected behavior:
Docker daemon as source should work with Docker version 25.0.0
Steps to reproduce:
cd examples/spring-boot
pom.xml
:docker pull eclipse-temurin:8-jre
./mvnw package jib:dockerBuild
jib-maven-plugin
Configuration:Log output:
Additional Information: Only happens with Docker 25.0.0 - no issues with older versions of Docker.