From 3b2676a655e8386657b7437fc0db63dd81c61b5b Mon Sep 17 00:00:00 2001 From: James Lu Date: Sun, 23 Feb 2020 21:52:57 -0800 Subject: [PATCH] atheme-docker first pass --- Dockerfile | 42 ++++++++++++++++++++++++++++++++++++++++++ README.md | 4 ++++ 2 files changed, 46 insertions(+) create mode 100644 Dockerfile create mode 100644 README.md diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..5bc8e93 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,42 @@ +FROM alpine:3.11 + +ARG ATHEME_VERSION=7.2.10-r2 +ARG CONFIGURE_ARGS=--enable-contrib +ARG ATHEME_UID=10000 + +RUN adduser -D -h /atheme -u $ATHEME_UID atheme +RUN mkdir /atheme-src + +# Install build-deps +RUN apk add --no-cache --virtual .build-deps \ + build-base \ + pkgconf \ + openssl-dev \ + # Used by contrib/gen_echoserver.so + libexecinfo-dev \ + git +# Runtime deps +RUN apk add openssl libexecinfo + +# Checkout from Git - we need to manually bump the libmowgli snapshot to fix compilation against musl +# This will be fixed when 7.3 releases +RUN git clone https://github.com/atheme/atheme -b v${ATHEME_VERSION} atheme-src --recursive +RUN cd /atheme-src/libmowgli-2 && git pull origin master + +# Configure and build +RUN cd /atheme-src && \ + ./configure --prefix=/atheme $CONFIGURE_ARGS +RUN cd /atheme-src && \ + make -j$(nproc) && make install + +# Remove source dir and build deps +RUN rm -rf /atheme-src && apk del .build-deps + +RUN chown -R atheme /atheme +USER atheme +# Services config +VOLUME /atheme/etc +# Services DB +VOLUME /atheme/var + +ENTRYPOINT ["/atheme/bin/atheme-services", "-n"] diff --git a/README.md b/README.md new file mode 100644 index 0000000..0611a44 --- /dev/null +++ b/README.md @@ -0,0 +1,4 @@ +# atheme-docker + +Unofficial Docker image for [Atheme IRC Services](https://github.com/atheme/atheme), based off Alpine. +