Files
thamanyah/cms/Dockerfile
T
fahd 9c95e0539a
Build, Push and Deploy CMS / build-push-deploy (push) Failing after 49s
INFRA: Dockerfile For CMS
2026-08-16 18:58:10 +03:00

21 lines
344 B
Docker

# syntax=docker/dockerfile:1
FROM golang:1.25-alpine AS builder
WORKDIR /src
COPY go.mod go.sum ./
RUN go mod download
COPY . .
RUN CGO_ENABLED=0 GOOS=linux go build -o /out/cms .
FROM alpine:3.20
RUN apk add --no-cache ca-certificates
WORKDIR /app
COPY --from=builder /out/cms ./cms
COPY static ./static
EXPOSE 8081
ENTRYPOINT ["./cms"]