„Dockerfile“ hinzufügen

This commit is contained in:
Manuel Weiser 2018-12-21 07:04:27 +00:00
parent e7a2385601
commit 46a3136f12

28
Dockerfile Normal file
View File

@ -0,0 +1,28 @@
# Builds a goaccess image from the current working directory:
FROM alpine:edge
COPY . /goaccess
WORKDIR /goaccess
ARG build_deps="build-base ncurses-dev autoconf automake git gettext-dev"
ARG runtime_deps="tini ncurses libintl gettext openssl-dev"
RUN apk update && \
apk add -u $runtime_deps $build_deps && \
apk add geoip-dev && apk add libmaxminddb-dev && apk add zlib-dev && apk add bzip2-dev && \
tar xzf tokyocabinet-1.4.48.tar.gz && cd tokyocabinet-1.4.48 && \
./configure && make && make install && cd ../ && \
autoreconf -fiv && \
./configure --enable-utf8 --with-openssl --enable-geoip=mmdb --enable-tcb=btree && \
make && \
make install && \
apk del $build_deps && \
rm -rf /var/cache/apk/* /tmp/goaccess/* /goaccess
VOLUME /srv/data
VOLUME /srv/logs
VOLUME /srv/report
EXPOSE 7890
ENTRYPOINT ["/sbin/tini", "--"]
CMD ["goaccess", "--no-global-config", "--config-file=/srv/data/goaccess.conf"]