cleanup with latest obs-build

This commit is contained in:
Frederic Crozat 2023-06-08 14:22:03 +02:00
parent a48cb7d15b
commit e275b73720

View File

@ -28,13 +28,14 @@ WORKDIR /src
FROM base AS build
ENV GO111MODULE=auto
# no need for full static build on BCI
ENV CGO_ENABLED=1
RUN --mount=type=bind,target=/src \
RUN --mount=type=bind,target=/src,rw \
--mount=type=cache,target=/root/.cache/go-build \
--mount=type=cache,target=/go/pkg/mod \
--mount=target=/go/pkg/mod,type=cache \
go build -o /go/bin/registry ./cmd/registry
FROM registry.suse.com/bci/bci-micro
FROM $BCI_MICRO
COPY cmd/registry/config-dev.yml /etc/docker/registry/config.yml
COPY --from=build /go/bin/registry /bin/registry
VOLUME ["/var/lib/registry"]