goipam/Dockerfile

12 lines
289 B
Docker
Raw Normal View History

2024-02-22 10:18:59 +01:00
FROM golang:alpine AS builder
RUN apk update && apk add --no-cache git
WORKDIR $GOPATH/src/goipam
COPY . .
RUN go get -d -v
RUN go build -a -installsuffix cgo -ldflags="-w -s" -o /go/bin/goipam
FROM scratch
COPY --from=builder /go/bin/goipam /go/bin/goipam
ENTRYPOINT ["/go/bin/goipam"]