-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
48 lines (40 loc) · 1.52 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
FROM alpine:latest
LABEL maintainer="Peter Boy <[email protected]>"
LABEL version="1.0"
# import config files
COPY config logging rights docker-entrypoint.sh /root/
# install everything in one run
RUN set -x \
&& apk add --no-cache \
python3 \
apache2-utils \
ca-certificates \
openssl \
su-exec \
shadow \
&& apk add --no-cache --virtual=build-deps \
python3-dev \
build-base \
libffi-dev \
git \
&& python3 -m pip install --upgrade pip \
&& python3 -m pip install passlib bcrypt \
&& python3 -m pip install radicale==2.1.11 \
&& python3 -m pip install --upgrade git+https://github.com/Unrud/RadicaleInfCloud \
&& apk del --purge build-deps \
&& mkdir -p /etc/radicale /srv/radicale \
&& mv /root/config /root/logging /root/rights /etc/radicale/ \
&& touch /etc/radicale/users \
&& mv /root/docker-entrypoint.sh /usr/local/bin/ \
&& chmod +x /usr/local/bin/docker-entrypoint.sh
# volume for Radicale persistent user data
# mount using -v /path/to/hostdir:/srv/radicale
VOLUME /srv/radicale
# tcp port for radicale, publish either on
# public interface with -p 5232:5232 or internal with --network=host
EXPOSE 5232
# set config environment variable
ENV RADICALE_CONFIG /etc/radicale/config
# set custom entrypoint
ENTRYPOINT ["docker-entrypoint.sh"]
CMD ["radicale"]