docker-radicale/README.md

80 lines
2.1 KiB
Markdown
Raw Permalink Normal View History

2021-03-17 00:28:46 +01:00
# Docker Radicale
This is a small docker image for [Radicale](https://github.com/Kozea/Radicale) and easy deployment. Bcrypt authentication inclusive.
2022-04-07 12:06:24 +02:00
![Docker Pulls](https://img.shields.io/docker/pulls/cupcakearmy/radicale?style=flat-square)
![Docker Image Size (tag)](https://img.shields.io/docker/image-size/cupcakearmy/radicale/latest?style=flat-square)
![Docker Image Version (tag latest semver)](https://img.shields.io/docker/v/cupcakearmy/radicale/latest?style=flat-square)
2021-03-17 00:31:13 +01:00
2021-03-17 00:28:46 +01:00
## Installation
2022-06-27 10:03:40 +02:00
```sh
2021-03-17 00:28:46 +01:00
# .env
USER=foo
PASSWORD=secret
```
2022-06-27 10:03:40 +02:00
```yaml
2021-03-17 00:28:46 +01:00
# docker-compose.yml
2022-06-27 10:03:40 +02:00
version: '3.8'
2021-03-17 00:28:46 +01:00
services:
app:
2021-05-05 12:27:48 +02:00
image: cupcakearmy/radicale:1
restart: unless-stopped
2021-03-17 00:28:46 +01:00
env_file: .env
volumes:
- ./data:/data
ports:
- 80:5232
```
The env file is not strictly required, but will generate a user with its bcrypt password if missing.
## macOS Setup
Without SSL/TLS the native client seems to have problems, once SSL is enabled it works like a charm.
![macOS Setup](.github/macOS.png)
The same setup works for Calendar and on iOS.
## Traefik
An example for traefik (v1) can found below.
2022-06-27 10:03:40 +02:00
```yaml
version: '3.8'
2021-03-17 00:28:46 +01:00
networks:
2022-06-27 10:03:40 +02:00
proxy:
2021-03-17 00:28:46 +01:00
external: true
services:
app:
2022-06-27 10:03:40 +02:00
image: cupcakearmy/radicale:1
restart: unless-stopped
2021-03-17 00:28:46 +01:00
env_file: .env
volumes:
- ./data:/data
networks:
2022-06-27 10:03:40 +02:00
- proxy
2021-03-17 00:28:46 +01:00
labels:
- traefik.enable=true
2022-06-27 10:03:40 +02:00
- traefik.http.routers.radicale.rule=Host(`radicale.example.org`)
- traefik.http.routers.radicale.entrypoints=secure
- traefik.http.routers.radicale.tls.certresolver=le
2021-03-17 00:28:46 +01:00
```
## Customize
### Config
You can overwrite the config by simply mounting it into `/etc/radicale/config`.
### User Auth
The default script only creates a default user with the given `USER` and `PASSWORD` credentials. For multiple users you need to create the files manually. In the default config this is set to `/data/users`.
You can add users with `htpasswd -bB -c /data/users user pass`. And then mount that file to `/data/users` or whatever you have set in the Radicale config file `filesystem_folder`, [more here](https://radicale.org/3.0.html#documentation/configuration/auth/htpasswd_filename).