feat: use goreleaser
Some checks failed
Golang Tests / unittest (stable, ubuntu-latest-amd64) (push) Failing after 15s
Golang Tests / unittest (stable, ubuntu-latest-arm64) (push) Failing after 15s
Markdown linter / markdown-lint (push) Failing after 13s
Golang CI lint / golangci (stable, ubuntu-latest-amd64) (push) Failing after 28s
Golang CI lint / golangci (stable, ubuntu-latest-arm64) (push) Failing after 2m39s

This commit is contained in:
2025-06-01 13:18:58 +02:00
parent 76f5437ab3
commit 9eed0fe492
8 changed files with 272 additions and 71 deletions

View File

@ -1,19 +1,5 @@
FROM docker.io/library/golang:1.24.3 AS build
FROM scratch AS build
WORKDIR /workspace
ADD . /workspace
COPY prometheus-fail2ban-exporter-* /usr/bin/prometheus-fail2ban-exporter
RUN apt update --yes && \
apt install --yes build-essential && \
make install \
PREFIX=/usr \
DESTDIR=/app \
EXECUTABLE=prometheus-fail2ban-exporter
FROM docker.io/library/debian:12-slim
COPY --from=build /app /
EXPOSE 9191
ENTRYPOINT [ "/usr/bin/prometheus-fail2ban-exporter" ]
ENTRYPOINT [ "/usr/bin/prometheus-fail2ban-exporter" ]