commit 5ec9e9bb454dbc99a6ddf2245b1de12a72febf85 parent df86527a52bed247f00bc976dfa3c314c017d235 Author: Andreas Gruhler <agruhl@gmx.ch> Date: Sat, 2 Aug 2025 19:31:24 +0200 feat(snac): add Dockerfile Diffstat:
A | docker/docker-snac/Dockerfile | | | 26 | ++++++++++++++++++++++++++ |
1 file changed, 26 insertions(+), 0 deletions(-)
diff --git a/docker/docker-snac/Dockerfile b/docker/docker-snac/Dockerfile @@ -0,0 +1,25 @@ +# https://codeberg.org/grunfink/snac2/src/branch/master/Dockerfile +ARG ALPINE_VERSION=latest + +FROM docker.io/alpine:${ALPINE_VERSION} AS builder + +ARG SNAC_VERSION="2.81" +ENV SNAC_VERSION="$SNAC_VERSION" + +# Download latest release +RUN mkdir -p /build +RUN wget -qO snac.tar.gz https://codeberg.org/grunfink/snac2/archive/${SNAC_VERSION}.tar.gz +RUN tar --strip-components=1 -C /build -xf snac.tar.gz + +# Install snac +RUN apk -U --no-progress --no-cache add curl-dev build-base && \ + cd /build && make && \ + make PREFIX="/build/out/usr/local" PREFIX_MAN="/build/out/usr/local/share/man" install + +# Run snac +FROM docker.io/alpine:${ALPINE_VERSION} +RUN apk -U --no-progress --no-cache add libcurl +COPY --from=builder /build/out / +EXPOSE 5050 +VOLUME [ "/data" ] +CMD [ "/bin/sh", "-c", "snac httpd /data/data" ] +\ No newline at end of file