nws/cmd/proxy/Dockerfile

17 lines
302 B
Docker
Raw Normal View History

2024-07-22 21:00:21 +00:00
FROM golang:1.21-alpine as builder
ADD . /build/
WORKDIR /build
RUN apk add --no-cache git bash openssh-client && \
go build -o proxy cmd/proxy/*.go
#building finished. Now extracting single bin in second stage.
FROM alpine
COPY --from=builder /build/proxy /app/
WORKDIR /app
CMD ["./proxy"]