radicale/Dockerfile

38 lines
963 B
Docker
Raw Normal View History

FROM alpine:latest
2014-10-20 00:10:19 +02:00
2016-06-24 17:40:43 +02:00
MAINTAINER Radicale project "radicale@librelist.com"
2016-06-26 17:01:44 +02:00
ENV VERSION 1.1.1
ENV TARBALL https://github.com/Kozea/Radicale/archive/${VERSION}.tar.gz
RUN apk --update --update-cache upgrade \
&& apk add \
python3 \
python3-dev \
build-base \
libffi-dev \
ca-certificates \
&& python3 -m ensurepip \
&& pip3 install --upgrade pip
2016-04-02 10:35:39 +02:00
2016-06-26 17:01:44 +02:00
RUN pip3 install passlib bcrypt
2014-10-20 00:10:19 +02:00
RUN mkdir -p /data/config
2016-06-26 17:01:44 +02:00
RUN wget ${TARBALL} \
&& tar xzf ${VERSION}.tar.gz \
&& cd Radicale-${VERSION} && python3 setup.py install
COPY config /data/config
2015-12-28 19:17:30 +01:00
# User
RUN adduser -h /home/radicale -D radicale \
&& mkdir -p /home/radicale/.config \
&& ln -s /data/config /home/radicale/.config/radicale \
&& chown -R radicale:radicale /data/config \
&& chown -R radicale:radicale /home/radicale
2016-03-28 10:51:36 +02:00
USER radicale
WORKDIR /home/radicale
2015-12-28 19:17:30 +01:00
CMD ["radicale", "-D", "-C", "/data/config/config"]