Skip to content

Instantly share code, notes, and snippets.

@IngwiePhoenix
Created March 25, 2024 13:43
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save IngwiePhoenix/633b3f92fa05e6ae2da83dd3bcad9965 to your computer and use it in GitHub Desktop.
Save IngwiePhoenix/633b3f92fa05e6ae2da83dd3bcad9965 to your computer and use it in GitHub Desktop.
Snort, in Docker, on Alpine, with dufs
FROM alpine:3.19 AS make-snort
RUN apk add nodejs npm git \
&& npm i -g yarn \
&& mkdir -p /opt/src \
&& git clone \
--depth 1 --single-branch -b main \
https://git.v0l.io/Kieran/snort.git \
/opt/src \
&& cd /opt/src \
&& yarn --network-timeout 1000000 \
&& yarn build
FROM alpine:3.19 AS make-dufs
RUN apk add wget \
&& wget https://github.com/sigoden/dufs/releases/download/v0.40.0/dufs-v0.40.0-$(uname -m)-unknown-linux-musl.tar.gz \
&& tar xvfz dufs*.tar.gz \
&& mv dufs /usr/bin/dufs
FROM alpine:3.19 AS final
RUN mkdir /www
WORKDIR /www
COPY --from=make-snort /opt/src/packages/app/build /www
COPY --from=make-dufs /usr/bin/dufs /usr/bin/dufs
CMD ["/usr/bin/dufs", "--render-spa", "--bind", "0.0.0.0", "/www"]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment