@ddg-gmbh/le-challenge-cloudflare
v1.3.1
Published
A Cloudflare challenge for greenlock
Downloads
13
Readme
@ddg-gmbh/le-challenge-cloudflare
greenlock
ACME dns-01
challenge for Cloudflare.
Prior Art
- certbot-dns-cloudflare: The official certbot reference implementation by the EFF
- llun/le-challenge-cloudflare
Usage
import Greenlock from 'greenlock';
import LEStoreCertbot from 'le-store-certbot';
import LEChallengeCloudflare from '@ddg-gmbh/le-challenge-cloudflare';
const store = LEStoreCertbot.create();
const DNSChallenge = new LEChallengeCloudflare({
cloudflare: {
email: process.env.cloudflare_email,
key: process.env.cloudflare_api_key,
},
acmePrefix: '_acme-challenge', // default
verifyPropagation: { waitFor: 5000, retries: 20 }, // default
useDNSOverHTTPS: false // default
});
const greenlock = Greenlock.create({
server: Greenlock.stagingServerUrl,
store,
challenges: { 'dns-01': DNSChallenge },
challengeType: 'dns-01'
});
greenlock.register({
domains: ['example.com'],
email: '[email protected]',
agreeTos: true,
rsaKeySize: 2048
});