Files
ax/Dockerfile

26 lines
399 B
Docker
Raw Normal View History

2026-04-01 15:12:00 +02:00
FROM golang:1.24-alpine AS builder
WORKDIR /app
ENV GOTOOLCHAIN=auto
COPY src/go.mod src/go.sum ./
2026-04-01 15:12:00 +02:00
RUN go mod download
COPY src/ ./
2026-04-01 15:12:00 +02:00
RUN CGO_ENABLED=0 GOOS=$TARGETOS GOARCH=$TARGETARCH \
go build -ldflags="-s -w" -trimpath -o /ax .
2026-04-01 15:12:00 +02:00
FROM alpine:latest
RUN apk --no-cache add ca-certificates
WORKDIR /data
COPY --from=builder /ax /usr/local/bin/ax
2026-04-01 15:12:00 +02:00
EXPOSE 7000
2026-04-02 02:36:54 +02:00
ENTRYPOINT ["ax", "serve"]