Pin external actions, images, toolchains, native archives, and tvOS engine artifacts; enforce fail-closed CI checks and keep website privacy disclosures aligned with shipped behavior.
17 lines
569 B
Docker
17 lines
569 B
Docker
# Update the readable tag, index digest, and platforms together using the controlled process in CONTRIBUTING.md.
|
|
# Platforms: linux/amd64, linux/arm64
|
|
FROM golang:1.22.12-alpine3.21@sha256:1699c10032ca2582ec89a24a1312d986a3f094aed3d5c1147b19880afe40e052 AS build
|
|
WORKDIR /src
|
|
COPY go.mod go.sum ./
|
|
RUN go mod download
|
|
COPY *.go .
|
|
RUN CGO_ENABLED=0 go build -ldflags="-s -w" -o /relay .
|
|
|
|
FROM scratch
|
|
COPY --from=build /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/
|
|
COPY --from=build /relay /relay
|
|
VOLUME /data
|
|
EXPOSE 8080
|
|
ENV GOMEMLIMIT=64MiB
|
|
ENTRYPOINT ["/relay"]
|