rcon-cli/Dockerfile

15 lines
215 B
Docker

FROM docker.io/golang:1.18 AS build
COPY ./go.* /src/
WORKDIR /src
RUN go mod download
COPY . /src
RUN CGO_ENABLED=0 go build -o /rcon-cli
FROM scratch
COPY --from=build /rcon-cli /
ENTRYPOINT [ "/rcon-cli" ]