mirror of
https://github.com/nyanotech/object-holder.git
synced 2026-02-08 05:47:26 -08:00
add first pass at a dockerfile
This commit is contained in:
17
Dockerfile
Normal file
17
Dockerfile
Normal file
@@ -0,0 +1,17 @@
|
||||
FROM golang:1.22-alpine AS builder
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
COPY go.mod go.sum ./
|
||||
RUN go mod download
|
||||
|
||||
COPY main.go ./
|
||||
RUN CGO_ENABLED=0 GOOS=linux go build -a -installsuffix cgo -o object-holder .
|
||||
|
||||
FROM alpine:latest
|
||||
|
||||
WORKDIR /root/
|
||||
|
||||
COPY --from=builder /app/object-holder .
|
||||
|
||||
ENTRYPOINT ["./object-holder"]
|
||||
Reference in New Issue
Block a user