postgresql-backuper/Dockerfile
2024-11-23 18:34:03 +05:00

12 lines
282 B
Docker

FROM golang:1.23-alpine AS builder
WORKDIR /app
COPY go.mod main.go ./
RUN go build -o main
FROM alpine:3.20
RUN apk add postgresql16-client
COPY --from=builder /app/main /usr/local/bin/postgresql-backuper
RUN mkdir /backups
ENV BACKUPS_DIR="/backups"
CMD ["postgresql-backuper"]