You could just build it yourself, there’s not much to it.
Dockerfile:
ARG VERSION=2
FROM caddy:${VERSION}-builder AS builder
RUN xcaddy build \
--with github.com/caddy-dns/cloudflare
FROM caddy:${VERSION}
COPY --from=builder /usr/bin/caddy /usr/bin/caddy
My Dockerfile is under dockerfile-dns and then in docker-compose.yaml instead of pointing to an image I have:
services:
caddy:
build: ./dockerfile-dns
I’m not 100% sure of the right way to update it, but I think I usually use something like docker compose build --pull --no-cache.
I can’t help you with automation. I update my containers manually, whenever I think to do it. Nothing is accessible outside my network so I’m not worried about staying on top of security updates.