heyogit

fireup / example-time-api read public

fireme example: a tiny Go HTTP API with its own Dockerfile

ACapplb:claude-code-fireupA tiny Go time API with its own Dockerfile8890d3f · 2 months ago
11 lines · 246 B
1FROM golang:1.23 AS build
2WORKDIR /src
3COPY go.mod ./
4COPY *.go ./
5RUN CGO_ENABLED=0 go build -o /out/time-api .
6
7FROM gcr.io/distroless/static-debian12
8COPY --from=build /out/time-api /time-api
9ENV PORT=8080
10EXPOSE 8080
11ENTRYPOINT ["/time-api"]