From aa430b17586f72cdfc4e064e63637228b74ea4dd Mon Sep 17 00:00:00 2001 From: Jose Henrique Date: Fri, 13 Mar 2026 22:02:23 -0300 Subject: [PATCH] adding dockerfile --- mindforge.cronjob/Dockerfile | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 mindforge.cronjob/Dockerfile diff --git a/mindforge.cronjob/Dockerfile b/mindforge.cronjob/Dockerfile new file mode 100644 index 0000000..d84187a --- /dev/null +++ b/mindforge.cronjob/Dockerfile @@ -0,0 +1,23 @@ +# Start from the official Golang image for building +FROM --platform=$BUILDPLATFORM golang:1.22-alpine AS builder + +ARG TARGETARCH +ARG TARGETOS + +WORKDIR /app +COPY . . +# Build statically for Linux +RUN CGO_ENABLED=0 GOOS=${TARGETOS} GOARCH=${TARGETARCH} go build -o mindforge-cronjob main.go + +# Use Alpine for running, with CA certificates for TLS +FROM alpine:latest +WORKDIR /app +RUN apk --no-cache add ca-certificates +COPY --from=builder /app/mindforge-cronjob . +ENV GIT_REPOSITORY="" +ENV GEMINI_API_KEY="" +ENV OPENAI_API_KEY="" +ENV DISCORD_WEBHOOK_URL="" +ENV HAVEN_NOTIFY_URL="" +ENV SSH_PRIVATE_KEY="" +ENTRYPOINT ["/app/mindforge-cronjob"]