2024-04-26 14:57:10 +05:30
|
|
|
FROM golang:alpine AS build
|
2022-06-18 01:24:45 +05:30
|
|
|
|
|
|
|
WORKDIR /app/
|
|
|
|
|
|
|
|
COPY . .
|
|
|
|
|
|
|
|
RUN --mount=type=cache,target=/root/.cache/go-build \
|
|
|
|
go build -ldflags "-s -w" main.go
|
|
|
|
|
2024-04-26 14:57:10 +05:30
|
|
|
FROM alpine
|
2022-06-18 01:24:45 +05:30
|
|
|
|
2024-04-27 18:00:35 +05:30
|
|
|
RUN apk --no-cache add --no-check-certificate ca-certificates dumb-init \
|
2024-04-26 14:57:10 +05:30
|
|
|
&& update-ca-certificates
|
2022-06-18 01:24:45 +05:30
|
|
|
|
|
|
|
|
2024-04-26 14:57:10 +05:30
|
|
|
COPY --from=build /app/main /ryd-proxy
|
2022-06-18 01:24:45 +05:30
|
|
|
|
2024-04-27 18:00:35 +05:30
|
|
|
ENTRYPOINT ["/usr/bin/dumb-init", "--"]
|
|
|
|
|
2022-06-18 01:24:45 +05:30
|
|
|
EXPOSE 3000
|
2024-04-27 18:00:35 +05:30
|
|
|
CMD "/ryd-proxy"
|