28 lines
949 B
Docker
28 lines
949 B
Docker
# 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"] |