You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

18 regels
348 B

  1. # syntax=docker/dockerfile:1
  2. FROM golang:1.24.0 AS builder
  3. WORKDIR /app
  4. COPY go.mod go.sum ./
  5. RUN go mod download
  6. COPY . .
  7. RUN CGO_ENABLED=0 GOOS=linux go build -a -installsuffix cgo -o location ./cmd/location
  8. FROM alpine:latest
  9. RUN apk add --no-cache ca-certificates
  10. WORKDIR /app
  11. COPY --from=builder /app/location .
  12. ENTRYPOINT ["./location"]