FROM caddy:2-builder AS builder

RUN xcaddy build \
    --with github.com/abiosoft/caddy-yaml \
    --with github.com/mholt/caddy-l4 \
    --with github.com/caddy-dns/porkbun

FROM caddy:2

COPY --from=builder /usr/bin/caddy /usr/bin/caddy
