1
0
Fork 0
mirror of https://github.com/Kozea/Radicale.git synced 2025-06-26 16:45:52 +00:00
Radicale/Dockerfile

35 lines
960 B
Text
Raw Normal View History

# This file is intended to be used apart from the containing source code tree.
2024-10-15 14:50:08 +05:45
FROM python:3-alpine AS builder
2014-10-20 00:10:19 +02:00
2021-12-20 22:33:38 +01:00
# Version of Radicale (e.g. v3)
ARG VERSION=master
# Optional dependencies (e.g. bcrypt)
ARG DEPENDENCIES=bcrypt
RUN apk add --no-cache --virtual gcc libffi-dev musl-dev \
&& python -m venv /app/venv \
&& /app/venv/bin/pip install --no-cache-dir "Radicale[${DEPENDENCIES}] @ https://github.com/Kozea/Radicale/archive/${VERSION}.tar.gz"
FROM python:3-alpine
WORKDIR /app
2024-03-13 00:19:41 -04:00
RUN addgroup -g 1000 radicale \
2024-03-13 00:04:29 -04:00
&& adduser radicale --home /var/lib/radicale --system --uid 1000 --disabled-password -G radicale \
&& apk add --no-cache ca-certificates openssl
2024-03-13 00:04:29 -04:00
COPY --chown=radicale:radicale --from=builder /app/venv /app
# Persistent storage for data
2017-06-10 16:15:45 +02:00
VOLUME /var/lib/radicale
# TCP port of Radicale
2016-06-26 19:29:18 +02:00
EXPOSE 5232
# Run Radicale
ENTRYPOINT [ "/app/bin/python", "/app/bin/radicale"]
2024-03-01 20:04:14 +10:00
CMD ["--hosts", "0.0.0.0:5232,[::]:5232"]
2020-08-07 02:28:22 +02:00
2024-03-01 20:04:14 +10:00
USER radicale