diff --git a/Dockerfile b/Dockerfile index a1556c69..ebf05c31 100644 --- a/Dockerfile +++ b/Dockerfile @@ -19,20 +19,24 @@ ENV CGO_ENABLED=0 WORKDIR /src FROM gobase AS buildx-version -RUN --mount=target=. \ - PKG=github.com/docker/buildx VERSION=$(git describe --match 'v[0-9]*' --dirty='.m' --always --tags) REVISION=$(git rev-parse HEAD)$(if ! git diff --no-ext-diff --quiet --exit-code; then echo .m; fi); \ - echo "-X ${PKG}/version.Version=${VERSION} -X ${PKG}/version.Revision=${REVISION} -X ${PKG}/version.Package=${PKG}" | tee /tmp/.ldflags; \ - echo -n "${VERSION}" | tee /tmp/.version; +RUN --mount=type=bind,target=. <" + exit 1 + ;; +esac