2019-03-08 18:47:06 +00:00
|
|
|
---
|
|
|
|
title: "Cloudflare"
|
|
|
|
date: 2019-03-03T16:39:46+01:00
|
|
|
|
draft: false
|
|
|
|
slug: cloudflare
|
|
|
|
---
|
|
|
|
|
|
|
|
<!-- THIS DOCUMENTATION IS AUTO-GENERATED. PLEASE DO NOT EDIT. -->
|
|
|
|
<!-- providers/dns/cloudflare/cloudflare.toml -->
|
|
|
|
<!-- THIS DOCUMENTATION IS AUTO-GENERATED. PLEASE DO NOT EDIT. -->
|
|
|
|
|
2019-04-17 19:32:38 +00:00
|
|
|
Since: v0.3.0
|
2019-03-08 18:47:06 +00:00
|
|
|
|
|
|
|
Configuration for [Cloudflare](https://www.cloudflare.com/dns/).
|
|
|
|
|
|
|
|
|
|
|
|
<!--more-->
|
|
|
|
|
|
|
|
- Code: `cloudflare`
|
|
|
|
|
|
|
|
Here is an example bash command using the Cloudflare provider:
|
|
|
|
|
|
|
|
```bash
|
|
|
|
CLOUDFLARE_EMAIL=foo@bar.com \
|
|
|
|
CLOUDFLARE_API_KEY=b9841238feb177a84330febba8a83208921177bffe733 \
|
|
|
|
lego --dns cloudflare --domains my.domain.com --email my@email.com run
|
|
|
|
```
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
## Credentials
|
|
|
|
|
|
|
|
| Environment Variable Name | Description |
|
|
|
|
|-----------------------|-------------|
|
2019-07-04 16:10:43 +00:00
|
|
|
| `CF_API_EMAIL` | Account email |
|
|
|
|
| `CF_API_KEY` | API key |
|
|
|
|
| `CLOUDFLARE_API_KEY` | Alias to CLOUDFLARE_API_KEY |
|
|
|
|
| `CLOUDFLARE_EMAIL` | Alias to CF_API_EMAIL |
|
2019-03-08 18:47:06 +00:00
|
|
|
|
2019-03-18 16:42:54 +00:00
|
|
|
The environment variable names can be suffixed by `_FILE` to reference a file instead of a value.
|
|
|
|
More information [here](/lego/dns/#configuration-and-credentials).
|
|
|
|
|
2019-03-08 18:47:06 +00:00
|
|
|
|
|
|
|
## Additional Configuration
|
|
|
|
|
|
|
|
| Environment Variable Name | Description |
|
|
|
|
|--------------------------------|-------------|
|
|
|
|
| `CLOUDFLARE_HTTP_TIMEOUT` | API request timeout |
|
|
|
|
| `CLOUDFLARE_POLLING_INTERVAL` | Time between DNS propagation check |
|
|
|
|
| `CLOUDFLARE_PROPAGATION_TIMEOUT` | Maximum waiting time for DNS propagation |
|
|
|
|
| `CLOUDFLARE_TTL` | The TTL of the TXT record used for the DNS challenge |
|
|
|
|
|
2019-03-18 16:42:54 +00:00
|
|
|
The environment variable names can be suffixed by `_FILE` to reference a file instead of a value.
|
|
|
|
More information [here](/lego/dns/#configuration-and-credentials).
|
|
|
|
|
2019-07-04 16:10:43 +00:00
|
|
|
The Global API Key needs to be used, not the Origin CA Key.
|
2019-03-08 18:47:06 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
## More information
|
|
|
|
|
|
|
|
- [API documentation](https://api.cloudflare.com/)
|
|
|
|
- [Go client](https://github.com/cloudflare/cloudflare-go)
|
|
|
|
|
|
|
|
<!-- THIS DOCUMENTATION IS AUTO-GENERATED. PLEASE DO NOT EDIT. -->
|
|
|
|
<!-- providers/dns/cloudflare/cloudflare.toml -->
|
|
|
|
<!-- THIS DOCUMENTATION IS AUTO-GENERATED. PLEASE DO NOT EDIT. -->
|