FROM r.batts.cloud/golang:1.19 as builder ARG VERSION=dev ARG COMMIT=unknown RUN apt-get update RUN curl -fsSL https://deb.nodesource.com/setup_18.x | bash RUN apt-get install -y \ build-essential \ nodejs \ python3-pip \ python3-venv WORKDIR /app ADD Makefile . # docs ADD ./requirements.txt . RUN make docs-deps ADD ./mkdocs.yml . ADD ./docs ./docs RUN make docs-build # web ADD ./web/package.json ./web/package-lock.json ./web/ RUN make web-deps ADD ./web ./web RUN make web-build # cli & server ADD go.mod go.sum main.go ./ ADD ./client ./client ADD ./cmd ./cmd ADD ./log ./log ADD ./server ./server ADD ./user ./user ADD ./util ./util RUN make VERSION=$VERSION COMMIT=$COMMIT cli-linux-server FROM r.batts.cloud/debian:testing LABEL org.opencontainers.image.authors="philipp.heckel@gmail.com" LABEL org.opencontainers.image.url="https://ntfy.sh/" LABEL org.opencontainers.image.documentation="https://docs.ntfy.sh/" LABEL org.opencontainers.image.source="https://github.com/binwiederhier/ntfy" LABEL org.opencontainers.image.vendor="Philipp C. Heckel" LABEL org.opencontainers.image.licenses="Apache-2.0, GPL-2.0" LABEL org.opencontainers.image.title="ntfy" LABEL org.opencontainers.image.description="Send push notifications to your phone or desktop using PUT/POST" COPY --from=builder /app/dist/ntfy_linux_server/ntfy /usr/bin/ntfy EXPOSE 80/tcp ENTRYPOINT ["ntfy"]