open-build-service
open-build-service copied to clipboard
Please make Docker "scratch" image available for build
Is your feature request related to a problem? Please describe. To achieve minimal image sizes, multi-layer docker builds are typically used. You start with a "big" image, install/copy/build what you need and finalize with
FROM opensuse/leap:15.3 as build
...
FROM scratch as final
COPY --from=build /usr/bin/final-binary /usr/bin/final-binary
However, scratch
is not a Docker build-in, but pulled from Docker hub.
So the above Dockerfile fails with
msg="Error getting v2 registry: Get "https://registry-1.docker.io/v2/": dial tcp: lookup registry-1.docker.io on [::1]:53: read udp [::1]:44522->[::1]:53: read: connection refused"
Describe the solution you'd like
scratch
is part of the build-service-provided registry and FROM scratch
in Docker builds doesn't fail.
Describe alternatives you've considered
There's no alternative to FROM scratch
when building with Docker.
Additional context https://build.opensuse.org/package/show/home:kwk:elemental:images/ros-operator-image
have you tried against the docker hub DoD project?
Just add Docker:Registry/standard as a path.
Have you tried with BuildEngine: podman
?
Just add Docker:Registry/standard as a path.
Done that. Project is blocked on waiting for dod resources to appear: container:suse/sle15:15.3
for ~24 hours now :-(