diff --git a/tasks/main.yml b/tasks/main.yml index 2558801..f91f64a 100644 --- a/tasks/main.yml +++ b/tasks/main.yml @@ -51,7 +51,7 @@ environment: LEGO_SERVER: "{{ lego_acme_server }}/directory" LEGO_PATH: "{{ __lego_base_dir }}/.lego" - CLOUDFLARE_API_TOKEN: "{{ lego_cloudflare_api_token }}" + CLOUDFLARE_DNS_API_TOKEN: "{{ lego_cloudflare_api_token }}" when: not item.skip_create | default(False) | bool loop: "{{ lego_certificates }}" loop_control: diff --git a/templates/cron-lego-renew.sh.j2 b/templates/cron-lego-renew.sh.j2 index e5757ce..732533e 100644 --- a/templates/cron-lego-renew.sh.j2 +++ b/templates/cron-lego-renew.sh.j2 @@ -4,7 +4,7 @@ export LEGO_SERVER="{{ lego_acme_server }}/directory" export LEGO_PATH="{{ __lego_base_dir }}/.lego" -export CLOUDFLARE_API_TOKEN="{{ lego_cloudflare_api_token }}" +export CLOUDFLARE_DNS_API_TOKEN="{{ lego_cloudflare_api_token }}" {% for cert in lego_certificates %} echo "$(date) checking for cert update for {{ ', '.join(cert.domains) }}."