Multiple accounts from same DNS provider

I am currently working on migrating a community project away from using an NGINX installation to making use of Caddy, mainly to reduce the amount of maintenance required and the complexity of the configuration.

We have multiple domains we need to provide credentials for from 3 different Cloudflare accounts to obtain certificates automatically through Caddy.
Based on my research, I haven’t found a way to do this other than running multiple instances of Caddy, which I would prefer not to do due to having to somehow proxy the connections to different ports and just creating a lot of added complexity.

Could anyone advise whether it is possible to specify different credentials for different domains, or to specify multiple sets of credentials for Caddy to try per domain?

Any help is much appreciated.

Hi @NEXUS2345, welcome to the Caddy community.

Looks like you’ve already gone ahead and opened a feature request here: https://github.com/mholt/caddy/issues/2484

That’s good, because as can be seen in the code currently, it’s not possible to set multiple accounts via the Caddyfile itself as suggested in Multiple domains with cloudflare challenge on different accounts - #5 by frame.

https://github.com/mholt/caddy/blob/44e3a97a6719424c184c8ce59e9ce6cea2dd052f/caddytls/setup.go#L244-L248

More discussion on this can take place over in the feature request issue.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.