Skip to main content

Buddy DNS Authenticator plugin for Certbot

Project description

Buddy DNS Authenticator plugin for Certbot

This plugin automates the process of completing a dns-01 challenge by creating, and subsequently removing, TXT records using the Buddy Rest API.

Issue a token

In your Buddy account create personal access token with scopes:

  • WORKSPACE

  • ZONE_WRITE

  • ZONE_READ

Installation

pip install certbot-dns-buddy

Usage

Via environment variable

export BUDDY_TOKEN=xxx
# pass workspace url domain
export BUDDY_WORKSPACE=yyy
# if you want to use different region than US
export BUDDY_BASE_URL=https://api.eu.buddy.works
certbot certonly \
   --authenticator dns-buddy \
   --agree-tos \
   -d 'foo.bar'

Via INI file

Certbot will emit a warning if it detects that the credentials file can be accessed by other users on your system. The warning reads “Unsafe permissions on credentials configuration file”, followed by the path to the credentials file. This warning will be emitted each time Certbot uses the credentials file, including for renewal, and cannot be silenced except by addressing the issue (e.g., by using a command like chmod 600 to restrict access to the file).

--authenticator dns-buddy

select the authenticator plugin (Required)

--dns-buddy-credentials

Buddy Token credentials INI file. (Required)

An example credentials.ini file:

dns_buddy_token = XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
dns_buddy_workspace = YYY
dns_buddy_base_url = https://api.eu.buddy.works

To start using DNS authentication for Buddy, pass the following arguments on certbot’s command line:

certbot certonly \
  --authenticator dns-buddy \
  --dns-buddy-credentials <path to file> \
  --agree-tos \
  -d 'foo.bar'

Automatic renewal

By default, certbot installs a service that periodically renews its certificates automatically. In order to do this, the command must know the API key, otherwise it will fail silently.

In order to enable automatic renewal for your wildcard certificates, you will need to edit /lib/systemd/system/certbot.service. In there, add the following line in Service, with <YOUR_API_TOKEN> replaced with your actual token:

Environment="BUDDY_TOKEN=<YOUR_API_TOKEN>"
Environment="BUDDY_WORKSPACE=<YOUR_API_TOKEN>"

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

certbot_dns_buddy-1.0.0-py3-none-any.whl (9.5 kB view details)

Uploaded Python 3

File details

Details for the file certbot_dns_buddy-1.0.0-py3-none-any.whl.

File metadata

File hashes

Hashes for certbot_dns_buddy-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 0e05eb55bc4b954ab288afe30e9fdaabd24725bc43afeba0947738c6c34ef07f
MD5 cc524dd2ed2f50eaeba65187d3832172
BLAKE2b-256 30cc7e80d28a0c10651e306a3d0119c6884589146283de8a126efffea7dc4d56

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page