github.com/blong14/gache@v0.0.0-20240124023949-89416fd8bbfa/docker/Dockerfile (about)

     1  FROM golang:1.20-bullseye AS go-build
     2  
     3  RUN apt-get update
     4  
     5  WORKDIR /go/src
     6  
     7  COPY go.mod /go/src
     8  COPY go.sum /go/src
     9  RUN go mod download
    10  
    11  COPY . /go/src
    12  RUN go build -o /go/bin/ github.com/blong14/gache/cmd/...
    13  
    14  FROM debian:bullseye-slim
    15  
    16  RUN apt-get update
    17  
    18  COPY --from=go-build /go/bin/gache /go/bin/gache
    19  COPY --from=go-build /go/bin/gctl /go/bin/gctl
    20  
    21  CMD ["/go/bin/gache"]