You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
docker_dokuwiki/Dockerfile

46 lines
1.6 KiB

10 years ago
# VERSION 0.1
# AUTHOR: Miroslav Prasil <miroslav@prasil.info>
# DESCRIPTION: Image with DokuWiki & lighttpd
# TO_BUILD: docker build -t mprasil/dokuwiki .
# TO_RUN: docker run -d -p 80:80 --name my_wiki mprasil/dokuwiki
FROM ubuntu:16.04
10 years ago
MAINTAINER Miroslav Prasil <miroslav@prasil.info>
# Set the version you want of Twiki
ARG DOKUWIKI_VERSION=2017-02-19e
ARG DOKUWIKI_CSUM=09bf175f28d6e7ff2c2e3be60be8c65f
10 years ago
ENV LAST_REFRESHED 25. October 2017
# Update & install packages & cleanup afterwards
RUN DEBIAN_FRONTEND=noninteractive \
apt-get update && \
apt-get -y upgrade && \
apt-get -y install wget lighttpd php-cgi php-gd php-ldap php-curl php-mbstring && \
apt-get clean autoclean && \
apt-get autoremove && \
rm -rf /var/lib/{apt,dpkg,cache,log}
# Download & check & deploy dokuwiki & cleanup
RUN wget -q -O /dokuwiki.tgz "http://download.dokuwiki.org/src/dokuwiki/dokuwiki-$DOKUWIKI_VERSION.tgz" && \
if [ "$DOKUWIKI_CSUM" != "$(md5sum /dokuwiki.tgz | awk '{print($1)}')" ];then echo "Wrong md5sum of downloaded file!"; exit 1; fi && \
mkdir /dokuwiki && \
tar -zxf dokuwiki.tgz -C /dokuwiki --strip-components 1 && \
rm dokuwiki.tgz
10 years ago
# Set up ownership
RUN chown -R www-data:www-data /dokuwiki
# Configure lighttpd
ADD dokuwiki.conf /etc/lighttpd/conf-available/20-dokuwiki.conf
RUN lighty-enable-mod dokuwiki fastcgi accesslog
RUN mkdir /var/run/lighttpd && chown www-data.www-data /var/run/lighttpd
EXPOSE 80
VOLUME ["/dokuwiki/data/","/dokuwiki/lib/plugins/","/dokuwiki/conf/","/dokuwiki/lib/tpl/","/var/log/"]
10 years ago
ENTRYPOINT ["/usr/sbin/lighttpd", "-D", "-f", "/etc/lighttpd/lighttpd.conf"]