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 0f1fc5601f
openpayments-mock / check (push) Has been skipped
openpayments-mock / vulnerabilities (push) Has been skipped
openpayments-mock / build (push) Successful in 3m20s
chore(deps): update golang docker tag to v1.26.5 (#15)
2026-07-11 00:08:33 +00:00

26 lines
760 B
Docker

FROM amd64/golang:1.26.5@sha256:0ca2a3f0102409fcafbe2cdd0cb0fe91f9ae8a67e25f9f6355a5352adda44f16 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"]