mirror of
https://github.com/zooai/cli.git
synced 2026-10-30 14:50:25 +00:00
Modules declare go 1.27.1 and the build images follow. go fix applied the modernizers; omitzero is not applied, since it changes what the JSON says. Co-authored-by: Hanzo Dev <[email protected]>
14 lines
398 B
Docker
14 lines
398 B
Docker
FROM golang:1.27.1-bookworm AS builder
|
|
ENV GOTOOLCHAIN=auto
|
|
WORKDIR /build
|
|
COPY go.mod ./
|
|
RUN go mod download || true
|
|
COPY . .
|
|
ENV CGO_ENABLED=0
|
|
RUN rm -f go.sum && go mod tidy && go build -o zoo-cli .
|
|
|
|
FROM debian:bookworm-slim
|
|
RUN apt-get update && apt-get install -y ca-certificates && rm -rf /var/lib/apt/lists/*
|
|
COPY --from=builder /build/zoo-cli /usr/local/bin/zoo-cli
|
|
ENTRYPOINT ["zoo-cli"]
|