Multi stage docker build
This commit is contained in:
parent
1758cfea65
commit
0b9a8e4ca1
@ -1,4 +1,9 @@
|
||||
FROM alpine:3
|
||||
COPY rbxcompiler /
|
||||
FROM registry.itzana.me/docker-proxy/library/golang:1.20 AS builder
|
||||
WORKDIR /go/src/git.itzana.me/itzaname/rbxcompiler
|
||||
COPY . ./
|
||||
RUN CGO_ENABLED=0 go build -a -installsuffix cgo -o /rbxcompiler ./cmd/rbxcompiler
|
||||
|
||||
FROM registry.itzana.me/docker-proxy/library/alpine:3
|
||||
COPY --from=builder /rbxcompiler /
|
||||
WORKDIR /stage
|
||||
ENTRYPOINT ["/rbxcompiler"]
|
Loading…
Reference in New Issue
Block a user