fail2ban-prometheus-exporter/Dockerfile.goreleaser
Hector f4d6598308 build: add manual docker multistep build (!114)
- Include two Dockerfiles in the repo: one for Goreleaser and one for manual builds
- Update the Goreleaser config to use it's own Dockerfile
- The Dockerfile for manual builds uses a two step process to build the exporter - this way the base system does not need Go installed

https://gitlab.com/hectorjsmith/fail2ban-prometheus-exporter/-/merge_requests/114
2023-10-27 06:01:41 +00:00

15 lines
375 B
Docker

FROM alpine
# Create main app folder to run from
WORKDIR /app
# Copy compiled binary to release image
# (must build the binary before running docker build)
COPY fail2ban_exporter /app/fail2ban_exporter
# Setup a healthcheck
COPY health /app/health
RUN apk add curl
HEALTHCHECK --interval=10s --timeout=4s --retries=3 CMD /app/health
ENTRYPOINT ["/app/fail2ban_exporter"]