ntfy-alertmanager/docker/Dockerfile
2023-07-19 16:38:40 +02:00

16 lines
478 B
Docker

FROM golang:alpine as build
WORKDIR /app
ARG VERSION=0.3.0
RUN wget https://git.xenrox.net/~xenrox/ntfy-alertmanager/refs/download/v${VERSION}/ntfy-alertmanager-${VERSION}.tar.gz -O latest.tar.gz && \
tar -zxf latest.tar.gz
RUN cd ntfy-alertmanager-${VERSION} && \
go build -ldflags="-X main.version=v${VERSION}" -o /app/ntfy-alertmanager
FROM alpine:latest
WORKDIR /
COPY --from=build /app/ntfy-alertmanager /ntfy-alertmanager
ENTRYPOINT [ "./ntfy-alertmanager" ]