This repository has been archived on 2026-07-20. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
openpayments-mock/Dockerfile
T
renovate 2ff0e230f2
renovate/stability-days Updates have met minimum release age requirement
openpayments-mock / check (pull_request) Successful in 41s
openpayments-mock / vulnerabilities (pull_request) Successful in 49s
openpayments-mock / build (pull_request) Successful in 1m16s
acctest Acceptance tests passed
chore(deps): update golang:1.26.5 docker digest to adde241
2026-07-14 06:08:17 +00:00

26 lines
760 B
Docker

FROM amd64/golang:1.26.5@sha256:adde24174d7535279e5649755947cdeb580ae549e9e9979006a544a8479db74a as modules
WORKDIR /build
ENV GOPRIVATE=gitea.unbound.se/shiny,gitea.unbound.se/unboundsoftware
ADD go.* /build
RUN go mod download
FROM modules as build
ARG CI_COMMIT
WORKDIR /build
ENV CGO_ENABLED=0
ADD . /build
RUN GOOS=linux GOARCH=amd64 go build \
-tags prod \
-a -installsuffix cgo \
-mod=readonly \
-o /release/service \
-ldflags "-w -s -X main.buildVersion=${CI_COMMIT}" \
./cmd/service
FROM scratch
ENV TZ Europe/Stockholm
COPY --from=build /usr/share/zoneinfo /usr/share/zoneinfo
COPY --from=build /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/
COPY --from=build /release/service /
CMD ["/service"]