Please see the Caddy Docker Image for deployment instructions.
Structure / idea is forked from Caddy community.
You can obtain your API token from the Cloudflare Portal.
-
To create a API token:
-
Log into your dashboard, go to account settings, create API token
-
grant the following permissions:
- Zone / Zone / Read
- Zone / DNS / Edit
-
-
You should add the following to your Caddyfile as the tls directives.
tls {$CLOUDFLARE_EMAIL} { dns cloudflare {$CLOUDFLARE_API_TOKEN} }
-
Add the following to your environment file (env):
CLOUDFLARE_EMAIL=me@example.com CLOUDFLARE_API_TOKEN=12345 ACME_AGREE=true