Files
eleith 9a17a3fc5b
ci/woodpecker/push/build-docker Pipeline was successful
ci/woodpecker/tag/build-docker Pipeline was successful
fix(docker): ensure dependencies are vendored inside container
this fixes local builds where the vendor directory is missing from the host.
it also aligns with standard practices of making the build self-contained.
ci pipelines still run vendor separately for lint/test steps, which is fine.
2025-12-21 13:00:15 -08:00

21 lines
470 B
Docker

FROM golang:1.24.5-alpine AS builder
WORKDIR /app
COPY go.mod go.sum ./
COPY cmd/ ./cmd/
COPY internal/ ./internal/
COPY web/static ./web/static
RUN go mod vendor
RUN CGO_ENABLED=0 GOOS=linux go build -mod=vendor -a -installsuffix cgo -o /app/miniflux-digest ./cmd/miniflux-digest
FROM alpine:3.22.1
WORKDIR /app
COPY --from=builder /app/miniflux-digest /app/miniflux-digest
COPY --from=builder /app/web/static /app/web/static
ENTRYPOINT ["/app/miniflux-digest"]