FROM golang:1.24 AS build

WORKDIR /src
COPY . .

# RUN CGO_ENABLED=0 GOOS=linux go build -o /app cmd/klinik-core-service
RUN CGO_ENABLED=0 GOOS=linux go build -o /app cmd/legalgo/main.go

RUN ls -la /

FROM gcr.io/distroless/static

WORKDIR /

COPY --from=build /usr/share/zoneinfo /usr/share/zoneinfo
COPY --from=build /app /app

# RUN ls -la /

ENV TZ=Asia/Jakarta

ENTRYPOINT ["/app"]
