fix: issues
This commit is contained in:
@@ -8,10 +8,13 @@ ARG COMMIT=dev
|
|||||||
WORKDIR /src
|
WORKDIR /src
|
||||||
COPY go.mod go.sum ./
|
COPY go.mod go.sum ./
|
||||||
RUN --mount=type=cache,target=/go/pkg/mod go mod download
|
RUN --mount=type=cache,target=/go/pkg/mod go mod download
|
||||||
COPY . .
|
COPY cmd ./cmd
|
||||||
|
COPY internal ./internal
|
||||||
RUN --mount=type=cache,target=/root/.cache/go-build \
|
RUN --mount=type=cache,target=/root/.cache/go-build \
|
||||||
|
cd /src \
|
||||||
|
ls -l \
|
||||||
CGO_ENABLED=0 GOOS=$TARGETOS GOARCH=$TARGETARCH \
|
CGO_ENABLED=0 GOOS=$TARGETOS GOARCH=$TARGETARCH \
|
||||||
go build -trimpath -ldflags "-s -w -X github.com/any-hub/any-hub/internal/version.Version=${VERSION} -X github.com/any-hub/any-hub/internal/version.Commit=${COMMIT}" -o /out/any-hub ./cmd/any-hub
|
go build -trimpath -ldflags "-s -w -X github.com/rogeecn/any-hub/internal/version.Version=${VERSION} -X github.com/rogeecn/any-hub/internal/version.Commit=${COMMIT}" -o /out/any-hub ./cmd/any-hub
|
||||||
|
|
||||||
FROM gcr.io/distroless/static-debian12:nonroot
|
FROM gcr.io/distroless/static-debian12:nonroot
|
||||||
COPY --from=builder /out/any-hub /usr/local/bin/any-hub
|
COPY --from=builder /out/any-hub /usr/local/bin/any-hub
|
||||||
|
|||||||
Reference in New Issue
Block a user