hardened-caddy-cloudflare
Docker Hardened Caddy + Caddy Cloudflare Plugin
10K+
Docker Hardened Caddy Image with Caddy Cloudflare Module
docker pull touhidurrr/hardened-caddy-cloudflare
Then follow this guide: https://hub.docker.com/hardened-images/catalog/dhi/caddy/guides
The documentation in DHI Guide is mostly fine, but a couple of things needs to be fixed for better persistance.
Config: /home/nonroot/.config/caddy
Data: /home/nonroot/.local/share/caddy
This compose.yml works:
services:
caddy:
image: touhidurrr/hardened-caddy-cloudflare
container_name: hardened-caddy-cloudflare
restart: always
ports:
- "80:80"
- "443:443"
- "443:443/udp"
volumes:
- ./caddy/Caddyfile:/etc/caddy/Caddyfile:ro
- ./caddy/data:/home/nonroot/.local/share/caddy
- ./caddy/config:/home/nonroot/.config/caddy
# (Optional) in case you are using Unix domain sockets like me
- ./sockets:/sockets
environment:
CF_API_TOKEN: <Your API Token>
Content type
Image
Digest
sha256:7227b6d77…
Size
33.7 MB
Last updated
about 2 hours ago
docker pull touhidurrr/hardened-caddy-cloudflare:2.11.4