Updated the Dockerfile to drop the ejr/feedkit replacement and to run go test before building.
Some checks failed
ci/woodpecker/manual/build-image Pipeline failed
Some checks failed
ci/woodpecker/manual/build-image Pipeline failed
This commit is contained in:
@@ -16,6 +16,7 @@ RUN apt-get update && apt-get install -y --no-install-recommends \
|
|||||||
|
|
||||||
# Cache dependencies first
|
# Cache dependencies first
|
||||||
COPY go.mod go.sum ./
|
COPY go.mod go.sum ./
|
||||||
|
RUN go mod edit -dropreplace gitea.maximumdirect.net/ejr/feedkit
|
||||||
RUN --mount=type=cache,target=/go/pkg/mod \
|
RUN --mount=type=cache,target=/go/pkg/mod \
|
||||||
go mod download
|
go mod download
|
||||||
|
|
||||||
@@ -31,7 +32,12 @@ ENV CGO_ENABLED=${CGO_ENABLED} \
|
|||||||
GOOS=${TARGETOS} \
|
GOOS=${TARGETOS} \
|
||||||
GOARCH=${TARGETARCH}
|
GOARCH=${TARGETARCH}
|
||||||
|
|
||||||
# Build your cmd entrypoint
|
# Run tests before building the final binary
|
||||||
|
RUN --mount=type=cache,target=/go/pkg/mod \
|
||||||
|
--mount=type=cache,target=/root/.cache/go-build \
|
||||||
|
go test ./...
|
||||||
|
|
||||||
|
# Build the cmd entrypoint
|
||||||
RUN --mount=type=cache,target=/root/.cache/go-build \
|
RUN --mount=type=cache,target=/root/.cache/go-build \
|
||||||
go build \
|
go build \
|
||||||
-trimpath \
|
-trimpath \
|
||||||
|
|||||||
Reference in New Issue
Block a user