Merge pull request #1071 from tiborvass/fix-osuser-panic
hack: fix runtime panic due to osuser build tag not setdocker-19.03
commit
db487c0cd0
|
@ -92,11 +92,10 @@ RUN --mount=target=. --mount=target=/root/.cache,type=cache \
|
|||
FROM buildkit-base AS buildkitd
|
||||
ARG TARGETPLATFORM
|
||||
ARG BUILDKITD_TAGS
|
||||
ENV BUILDKITD_TAGS="osusergo netgo static_build seccomp ${BUILDKITD_TAGS}"
|
||||
RUN --mount=target=. --mount=target=/root/.cache,type=cache \
|
||||
--mount=target=/go/pkg/mod,type=cache \
|
||||
--mount=source=/tmp/.ldflags,target=/tmp/.ldflags,from=buildkit-version \
|
||||
go build -ldflags "$(cat /tmp/.ldflags) -w -extldflags -static" -tags "${BUILDKITD_TAGS}" -o /usr/bin/buildkitd ./cmd/buildkitd && \
|
||||
go build -ldflags "$(cat /tmp/.ldflags) -w -extldflags -static" -tags "osusergo netgo static_build seccomp ${BUILDKITD_TAGS}" -o /usr/bin/buildkitd ./cmd/buildkitd && \
|
||||
file /usr/bin/buildkitd | egrep "statically linked|Windows"
|
||||
|
||||
FROM scratch AS binaries-linux
|
||||
|
|
Loading…
Reference in New Issue