feat: ✨ add dockerfile
This commit is contained in:
parent
96a95e2dc7
commit
2457914641
20
Dockerfile
Normal file
20
Dockerfile
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
FROM golang:1.22 as builder
|
||||||
|
|
||||||
|
WORKDIR /plugin
|
||||||
|
|
||||||
|
COPY go.mod go.sum ./
|
||||||
|
RUN go mod download
|
||||||
|
|
||||||
|
COPY . .
|
||||||
|
RUN go build -o plugin
|
||||||
|
|
||||||
|
FROM alpine:3.6 as alpine
|
||||||
|
RUN apk add -U --no-cache ca-certificates
|
||||||
|
|
||||||
|
FROM alpine:3.6
|
||||||
|
ENV GODEBUG netdns=go
|
||||||
|
|
||||||
|
COPY --from=alpine /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/
|
||||||
|
|
||||||
|
COPY --from=builder /plugin/plugin /bin/
|
||||||
|
ENTRYPOINT ["/bin/plugin"]
|
Loading…
Reference in New Issue
Block a user