我正试图用Jib来封装和创建我的春季引导应用程序的图像。其要求是它应该运行在一个windows容器上,因此我的基本映像是eclipse:8-nanoserver。https://hub.docker.com/r/winamd64/eclipse-temurin/
每当我构建我的映像时,我都会得到以下错误:
[ERROR] Failed to execute goal com.google.cloud.tools:jib-maven-plugin:3.2.1:dockerBuild (push-custom-tag) on project snmp-microservice: com.google.cloud.tools.jib.registry.RegistryErrorException: Tried to pull BLOB for registry-1.docker.io/library/eclipse-temurin with digest sha256:2ebf439f800cd4c1fccaf4a0545e6bff60caa5141295c8ab81f6c525073c423d but failed because: blob unknown to registry (something went wrong): 404 Not Found
[ERROR] {"errors":[{"code":"BLOB_UNKNOWN","message":"blob unknown to registry","detail":"sha256:2ebf439f800cd4c1fccaf4a0545e6bff60caa5141295c8ab81f6c525073c423d"}]}
[ERROR] -> [Help 1]这就是jib在我的pom.xml中的样子:
<profiles>
<profile>
<id>jib-push-to-local</id>
<activation>
<activeByDefault>false</activeByDefault>
</activation>
<build>
<plugins>
<plugin>
<groupId>com.google.cloud.tools</groupId>
<artifactId>jib-maven-plugin</artifactId>
<version>3.2.1</version>
<configuration>
<from>
<image>eclipse-temurin:8-nanoserver</image>
<platforms>
<platform>
<architecture>amd64</architecture>
<os>windows</os>
</platform>
</platforms>
</from>
<container>
<ports>
<port>8080</port>
</ports>
<format>OCI</format>
</container>
</configuration>
<executions>
<execution>
<id>push-custom-tag</id>
<phase>package</phase>
<configuration>
<to>
<image>amb/${app.image.name}:${version}</image>
</to>
</configuration>
<goals>
<goal>dockerBuild</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
</profiles>我正在使用坞窗口,停靠版本显示:
Client:
Version: master-dockerproject-2022-03-26
API version: 1.42
Go version: go1.17.8
Git commit: dd7397342a
Built: Sun Mar 27 00:09:40 2022
OS/Arch: windows/amd64
Context: default
Experimental: true
Server: Docker Engine - Community
Engine:
Version: master-dockerproject-2022-03-26
API version: 1.42 (minimum version 1.24)
Go version: go1.18
Git commit: 8941dcfcc5
Built: Sun Mar 27 00:05:42 2022
OS/Arch: windows/amd64
Experimental: false值得指出的是,对于具有windows基本映像的任何版本的eclipse temurin,我都会使用jib,我试着拉出windowsservercore和nanoserver,以及他们提供的所有相关版本,但尽管我遇到了同样的问题,我认为Jib可能不支持windows构建。如果我创建了一个Dockerfile,并且我没有使用Jib,那么所有的东西都工作得很完美,但是我真的很想使用Jib。有什么好主意吗?
发布于 2022-08-19 09:00:17
码头登记似乎存在问题,至少目前是这样的:
这意味着HTTP 404是对expect的响应。
https://stackoverflow.com/questions/73413510
复制相似问题