certbot-dns-porkbun


Namecertbot-dns-porkbun JSON
Version 0.9.1 PyPI version JSON
download
home_pagehttps://github.com/infinityofspace/certbot_dns_porkbun
SummaryPlugin for certbot to obtain certificates using a DNS TXT record for Porkbun domains
upload_time2024-11-24 21:22:12
maintainerNone
docs_urlNone
authorinfinityofspace
requires_python>=3.9
licenseMIT
keywords
VCS
bugtrack_url
requirements setuptools certbot pkb_client dnspython tldextract
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # Certbot DNS Porkbun Plugin

Plugin for certbot to obtain certificates using a DNS TXT record for Porkbun domains

---

![PyPI - Python Version](https://img.shields.io/pypi/pyversions/certbot_dns_porkbun?style=for-the-badge)
[![GitHub](https://img.shields.io/github/license/infinityofspace/certbot_dns_porkbun?style=for-the-badge)](https://github.com/infinityofspace/certbot_dns_porkbun/blob/master/License)

[![PyPI](https://img.shields.io/pypi/v/certbot_dns_porkbun?style=for-the-badge)](https://pypi.org/project/certbot-dns-porkbun/)
![PyPI - Downloads](https://img.shields.io/pypi/dm/certbot_dns_porkbun?style=for-the-badge)
[![GitHub Workflow Status](https://img.shields.io/github/actions/workflow/status/infinityofspace/certbot_dns_porkbun/pypi-build-test.yml?branch=main&style=for-the-badge)](https://github.com/infinityofspace/certbot_dns_porkbun/actions/workflows/pypi-build-test.yml)

[![Docker Image Version (latest semver)](https://img.shields.io/docker/v/infinityofspace/certbot_dns_porkbun?style=for-the-badge&sort=semver&label=Docker)](https://hub.docker.com/r/infinityofspace/certbot_dns_porkbun)
![Docker Pulls](https://img.shields.io/docker/pulls/infinityofspace/certbot_dns_porkbun?style=for-the-badge)
![Docker Image Size (tag)](https://img.shields.io/docker/image-size/infinityofspace/certbot_dns_porkbun/latest?style=for-the-badge)
[![GitHub Workflow Status](https://img.shields.io/github/actions/workflow/status/infinityofspace/certbot_dns_porkbun/docker-publish-unstable.yml?branch=main&style=for-the-badge)](https://github.com/infinityofspace/certbot_dns_porkbun/actions/workflows/docker-publish-unstable.yml)

[![certbot-dns-porkbun](https://snapcraft.io/certbot-dns-porkbun/badge.svg)](https://snapcraft.io/certbot-dns-porkbun)

---

### Table of Contents

1. [About](#about)
2. [Installation](#installation)
   1. [Prerequirements](#prerequirements)
   2. [With pip (recommend)](#with-pip-recommend)
   3. [From source](#from-source)
   4. [Snap](#snap)
3. [Usage](#usage)
   1. [Local installation](#local-installation)
   2. [Credentials file or cli parameters](#credentials-file-or-cli-parameters)   
   3. [Docker](#docker)
4. [FAQ](#faq)
5. [Third party notices](#third-party-notices)
6. [License](#license)

---

### About

_certbot_dns_porkbun_ is a plugin for [_certbot_](https://github.com/certbot/certbot). It handles the TXT record for the
DNS-01 challenge for Porkbun domains. The plugin takes care of the creation and deletion of the TXT record using the
Porkbun API.

### Installation

#### Prerequirements

If you want to use the docker image, then you don't need any requirements other than a working docker installation and
can proceed directly with the [usage](#docker)

You need at least version `3.7` of Python installed. If you want to install the plugin with pip, then you must also have
pip installed beforehand.

If you already have _certbot_ installed, make sure you have at least version `1.18.0` installed. When you installed
*certbot* as snap then you have to use the [snap installation](#snap) of the plugin.

You can check what version of _certbot_ is installed with this command:

```commandline
certbot --version
```

If you don't have certbot installed yet, then the PyPI version of certbot will be installed automatically during the
installation.

**Note: If you want to run certbot with root privileges, then you need to install the plugin as root too. Otherwise,
certbot cannot find the plugin.**

#### With pip (recommend)

Use the following command to install _certbot_dns_porkbun_ with pip:

```commandline
pip3 install certbot_dns_porkbun
```

You can also very easily update to the newest version:

```commandline
pip3 install certbot_dns_porkbun -U
```

#### From source

If you prefer to install the plugin from the source code:

```commandline
git clone https://github.com/infinityofspace/certbot_dns_porkbun.git
cd certbot_dns_porkbun
pip3 install .
```

#### Snap

If you use the *certbot* as snap package then you have to install *certbot_dns_porkbun* as a snap too:

```commandline
snap install certbot-dns-porkbun
```

Now connect the *certbot* snap installation with the plugin snap installation:

```commandline
sudo snap connect certbot:plugin certbot-dns-porkbun
```

The following command should now list `dns-porkbun` as an installed plugin:

```commandline
certbot plugins
```

### Usage

**Note: By default, Porkbun domains cannot be controlled through the API. This will cause an error when you generate certificates. Ensure that you have enabled API Access in your domain's settings to avoid this. If you haven't already, be sure to also delete the (default) parked domain ALIAS records, as not doing so may cause errors.**

#### Local installation

To check if the plugin is installed and detected properly by certbot, you can use the following command:

```commandline
certbot plugins
```

The resulting list should include `dns-porkbun` if everything went fine.

#### Credentials file or cli parameters

You can either use cli parameters to pass authentication information to certbot:

```commandline
...
--dns-porkbun-key <your-porkbun-api-key> \
--dns-porkbun-secret <your-porkbun-api-secret>
```

Or to prevent your credentials from showing up in your bash history, you can also create a
credentials-file `porkbun.ini` (the name does not matter) with the following content:

```ini
dns_porkbun_key=<your-porkbun-api-key>
dns_porkbun_secret=<your-porkbun-api-secret>
```

And then instead of using the `--dns-porkbun-key` and `--dns-porkbun-secret` parameters above you can use

```commandline
...
--dns-porkbun-credentials </path/to/your/porkbun.ini>
```

You can also mix these usages, though the cli parameters always take precedence over the ini file.

#### Examples

Below are some examples of how to use the plugin.

---

Generate a certificate with a DNS-01 challenge for the domain `example.org`:

```commandline
certbot certonly \
  --non-interactive \
  --agree-tos \
  --email <your-email-address> \
  --preferred-challenges dns \
  --authenticator dns-porkbun \
  --dns-porkbun-key <your-porkbun-api-key> \
  --dns-porkbun-secret <your-porkbun-api-secret> \
  --dns-porkbun-propagation-seconds 60 \
  -d "example.com"
```

---

Generate a wildcard certificate with a DNS-01 challenge for all subdomains `*.example.com` (Note: the wildcard
certificate does not contain the root domain itself):

```commandline
certbot certonly \
  --non-interactive \
  --agree-tos \
  --email <your-email-address> \
  --preferred-challenges dns \
  --authenticator dns-porkbun \
  --dns-porkbun-key <your-porkbun-api-key> \
  --dns-porkbun-secret <your-porkbun-api-secret> \
  --dns-porkbun-propagation-seconds 60 \
  -d "*.example.com"
```

---

Generate a certificate with a DNS-01 challenge for the domain `example.org` using a credentials ini file:

```commandline
certbot certonly \
  --non-interactive \
  --agree-tos \
  --email <your-email-address> \
  --preferred-challenges dns \
  --authenticator dns-porkbun \
  --dns-porkbun-credentials </path/to/your/porkbun.ini> \
  --dns-porkbun-propagation-seconds 60 \
  -d "example.com"
```

---

Generate a certificate with a DNS-01 challenge for the domain `example.com` without an account (i.e. without an email
address):

```commandline
certbot certonly \
  --non-interactive \
  --agree-tos \
  --register-unsafely-without-email \
  --preferred-challenges dns \
  --authenticator dns-porkbun \
  --dns-porkbun-key <your-porkbun-api-key> \
  --dns-porkbun-secret <your-porkbun-api-secret> \
  --dns-porkbun-propagation-seconds 60 \
  -d "example.com"
```

---

Generate a staging certificate (i.e. temporary testing certificate) with a DNS-01 challenge for the
domain `example.com`:

```commandline
certbot certonly \
  --non-interactive \
  --agree-tos \
  --email <your-email-address> \
  --preferred-challenges dns \
  --authenticator dns-porkbun \
  --dns-porkbun-key <your-porkbun-api-key> \
  --dns-porkbun-secret <your-porkbun-api-secret> \
  --dns-porkbun-propagation-seconds 60 \
  -d "example.com" \
  --staging
```

---

The DNS-01 challenge specification allows to forward the challenge to another domain by CNAME entries and thus to 
perform the validation from another domain.

For example, we have the domain `example.com` and `mydomain.com`. The nameservers of `example.com` domain are the  
Porkbun nameserver and `mydomain.com` is somewhere else. 
In order to perform a DNS-01 challenge for the domain `mydomain.com`, we only need to add this 
`_acme-challenge.mydomain.com` to `_acme-challenge.example.com` CNAME entry in advance:

```commandline
_acme-challenge.mydomain.com. 600 IN CNAME _acme-challenge.example.com.
```

Then we can use our Porkbun domain for the actual DNS-01 challenge.
The procedure is identical as if we perform a DNS-01 challenge for a Porkbun domain, except that the domain name for 
which we perform the challenge is now `mydomain.com` instead of Porkbun's `example.com`.

```commandline
certbot certonly \
  --non-interactive \
  --agree-tos \
  --email <your-email-address> \
  --preferred-challenges dns \
  --authenticator dns-porkbun \
  --dns-porkbun-key <your-porkbun-api-key> \
  --dns-porkbun-secret <your-porkbun-api-secret> \
  --dns-porkbun-propagation-seconds 60 \
  -d "mydomain.com"
```

What happens in the background is that the CNAME entry is followed to the end and then a TXT entry is created with the 
form `_acme-challenge.example.com.` for the found `example.com` Prokbun domain.
Thus, during the challenge of this example, the DNS would look like this:

```commandline
_acme-challenge.mydomain.com. 600 IN CNAME _acme-challenge.example.com.
_acme-challenge.example.com. 60 TXT "a8sdhb09a7sbd08ashd90ashd90a8hsa9usd"
```

---

You can find al list of all available certbot cli options in
the [official documentation](https://certbot.eff.org/docs/using.html#certbot-command-line-options) of _certbot_.

#### Docker

You can simply start a new container and use the same certbot commands to obtain a new certificate:

```commandline
docker run -v "/etc/letsencrypt:/etc/letsencrypt" -v "/var/log/letsencrypt:/var/log/letsencrypt" infinityofspace/certbot_dns_porkbun:latest \
   certonly \
     --non-interactive \
     --agree-tos \
     --email <your-email-address> \
     --preferred-challenges dns \
     --authenticator dns-porkbun \
     --dns-porkbun-key <your-porkbun-api-key> \
     --dns-porkbun-secret <your-porkbun-api-secret> \
     --dns-porkbun-propagation-seconds 60 \
     -d "example.com"
```

Or you can use a credentials file:

```commandline
docker run -v "/etc/letsencrypt:/etc/letsencrypt" -v "/var/log/letsencrypt:/var/log/letsencrypt" -v "/absolute/path/to/your/porkbun.ini:/conf/porkbun.ini" infinityofspace/certbot_dns_porkbun:latest \
   certonly \
     --non-interactive \
     --agree-tos \
     --email <your-email-address> \
     --preferred-challenges dns \
     --authenticator dns-porkbun \
     --dns-porkbun-credentials /conf/porkbun.ini \
     --dns-porkbun-propagation-seconds 60 \
     -d "example.com"
```

### Development

#### Setup environment

First get the source code:

```commandline
git clone https://github.com/infinityofspace/certbot_dns_porkbun.git
cd certbot_dns_porkbun
```

Now create a virtual environment, activate it and install all dependencies with the following commands:

```commandline
python3 -m venv venv
source venv/bin/activate
pip3 install -r requirements.txt
```

Now you can start developing.

Feel free to contribute to this project by creating a pull request.
Before you create a pull request, make sure that you code meets the following requirements (you can use the specified
commands to check/fulfill the requirements):

- check unit tests: `python -m unittest tests/*.py`
- format the code: `ruff format`
- check linting errors:
```commandline
flake8 certbot_dns_porkbun --count --ignore E501 --show-source --statistics
pylint certbot_dns_porkbun --disable C0301
```

#### Tests

You can run the tests with the following command:

```commandline
python -m unittest tests/*.py
```

### Third party notices

All modules used by this project are listed below:

|                            Name                             |                                                License                                                |
|:-----------------------------------------------------------:|:-----------------------------------------------------------------------------------------------------:|
|        [certbot](https://github.com/certbot/certbot)        |          [Apache 2.0](https://raw.githubusercontent.com/certbot/certbot/master/LICENSE.txt)           |
|      [setuptools](https://github.com/pypa/setuptools)       |                 [MIT](https://raw.githubusercontent.com/pypa/setuptools/main/LICENSE)                 |
| [pkb_client](https://github.com/infinityofspace/pkb_client) |                [MIT](https://github.com/infinityofspace/pkb_client/blob/main/License)                 |
|     [dnspython](https://github.com/rthalley/dnspython)      |              [ISC](https://raw.githubusercontent.com/rthalley/dnspython/master/LICENSE)               |
| [tldextract](https://github.com/john-kurkowski/tldextract)  | [BSD 3-Clause](https://raw.githubusercontent.com/john-kurkowski/tldextract/refs/heads/master/LICENSE) |

Furthermore, this readme file contains embeddings of [Shields.io](https://github.com/badges/shields).

### License

[MIT](https://github.com/infinityofspace/certbot_dns_porkbun/blob/master/License) - Copyright (c) Marvin Heptner

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/infinityofspace/certbot_dns_porkbun",
    "name": "certbot-dns-porkbun",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.9",
    "maintainer_email": null,
    "keywords": null,
    "author": "infinityofspace",
    "author_email": null,
    "download_url": "https://files.pythonhosted.org/packages/d6/51/6cae36eba174488c819f77b3bc25b582545df5099bb7108f02665be64603/certbot_dns_porkbun-0.9.1.tar.gz",
    "platform": null,
    "description": "# Certbot DNS Porkbun Plugin\n\nPlugin for certbot to obtain certificates using a DNS TXT record for Porkbun domains\n\n---\n\n![PyPI - Python Version](https://img.shields.io/pypi/pyversions/certbot_dns_porkbun?style=for-the-badge)\n[![GitHub](https://img.shields.io/github/license/infinityofspace/certbot_dns_porkbun?style=for-the-badge)](https://github.com/infinityofspace/certbot_dns_porkbun/blob/master/License)\n\n[![PyPI](https://img.shields.io/pypi/v/certbot_dns_porkbun?style=for-the-badge)](https://pypi.org/project/certbot-dns-porkbun/)\n![PyPI - Downloads](https://img.shields.io/pypi/dm/certbot_dns_porkbun?style=for-the-badge)\n[![GitHub Workflow Status](https://img.shields.io/github/actions/workflow/status/infinityofspace/certbot_dns_porkbun/pypi-build-test.yml?branch=main&style=for-the-badge)](https://github.com/infinityofspace/certbot_dns_porkbun/actions/workflows/pypi-build-test.yml)\n\n[![Docker Image Version (latest semver)](https://img.shields.io/docker/v/infinityofspace/certbot_dns_porkbun?style=for-the-badge&sort=semver&label=Docker)](https://hub.docker.com/r/infinityofspace/certbot_dns_porkbun)\n![Docker Pulls](https://img.shields.io/docker/pulls/infinityofspace/certbot_dns_porkbun?style=for-the-badge)\n![Docker Image Size (tag)](https://img.shields.io/docker/image-size/infinityofspace/certbot_dns_porkbun/latest?style=for-the-badge)\n[![GitHub Workflow Status](https://img.shields.io/github/actions/workflow/status/infinityofspace/certbot_dns_porkbun/docker-publish-unstable.yml?branch=main&style=for-the-badge)](https://github.com/infinityofspace/certbot_dns_porkbun/actions/workflows/docker-publish-unstable.yml)\n\n[![certbot-dns-porkbun](https://snapcraft.io/certbot-dns-porkbun/badge.svg)](https://snapcraft.io/certbot-dns-porkbun)\n\n---\n\n### Table of Contents\n\n1. [About](#about)\n2. [Installation](#installation)\n   1. [Prerequirements](#prerequirements)\n   2. [With pip (recommend)](#with-pip-recommend)\n   3. [From source](#from-source)\n   4. [Snap](#snap)\n3. [Usage](#usage)\n   1. [Local installation](#local-installation)\n   2. [Credentials file or cli parameters](#credentials-file-or-cli-parameters)   \n   3. [Docker](#docker)\n4. [FAQ](#faq)\n5. [Third party notices](#third-party-notices)\n6. [License](#license)\n\n---\n\n### About\n\n_certbot_dns_porkbun_ is a plugin for [_certbot_](https://github.com/certbot/certbot). It handles the TXT record for the\nDNS-01 challenge for Porkbun domains. The plugin takes care of the creation and deletion of the TXT record using the\nPorkbun API.\n\n### Installation\n\n#### Prerequirements\n\nIf you want to use the docker image, then you don't need any requirements other than a working docker installation and\ncan proceed directly with the [usage](#docker)\n\nYou need at least version `3.7` of Python installed. If you want to install the plugin with pip, then you must also have\npip installed beforehand.\n\nIf you already have _certbot_ installed, make sure you have at least version `1.18.0` installed. When you installed\n*certbot* as snap then you have to use the [snap installation](#snap) of the plugin.\n\nYou can check what version of _certbot_ is installed with this command:\n\n```commandline\ncertbot --version\n```\n\nIf you don't have certbot installed yet, then the PyPI version of certbot will be installed automatically during the\ninstallation.\n\n**Note: If you want to run certbot with root privileges, then you need to install the plugin as root too. Otherwise,\ncertbot cannot find the plugin.**\n\n#### With pip (recommend)\n\nUse the following command to install _certbot_dns_porkbun_ with pip:\n\n```commandline\npip3 install certbot_dns_porkbun\n```\n\nYou can also very easily update to the newest version:\n\n```commandline\npip3 install certbot_dns_porkbun -U\n```\n\n#### From source\n\nIf you prefer to install the plugin from the source code:\n\n```commandline\ngit clone https://github.com/infinityofspace/certbot_dns_porkbun.git\ncd certbot_dns_porkbun\npip3 install .\n```\n\n#### Snap\n\nIf you use the *certbot* as snap package then you have to install *certbot_dns_porkbun* as a snap too:\n\n```commandline\nsnap install certbot-dns-porkbun\n```\n\nNow connect the *certbot* snap installation with the plugin snap installation:\n\n```commandline\nsudo snap connect certbot:plugin certbot-dns-porkbun\n```\n\nThe following command should now list `dns-porkbun` as an installed plugin:\n\n```commandline\ncertbot plugins\n```\n\n### Usage\n\n**Note: By default, Porkbun domains cannot be controlled through the API. This will cause an error when you generate certificates. Ensure that you have enabled API Access in your domain's settings to avoid this. If you haven't already, be sure to also delete the (default) parked domain ALIAS records, as not doing so may cause errors.**\n\n#### Local installation\n\nTo check if the plugin is installed and detected properly by certbot, you can use the following command:\n\n```commandline\ncertbot plugins\n```\n\nThe resulting list should include `dns-porkbun` if everything went fine.\n\n#### Credentials file or cli parameters\n\nYou can either use cli parameters to pass authentication information to certbot:\n\n```commandline\n...\n--dns-porkbun-key <your-porkbun-api-key> \\\n--dns-porkbun-secret <your-porkbun-api-secret>\n```\n\nOr to prevent your credentials from showing up in your bash history, you can also create a\ncredentials-file `porkbun.ini` (the name does not matter) with the following content:\n\n```ini\ndns_porkbun_key=<your-porkbun-api-key>\ndns_porkbun_secret=<your-porkbun-api-secret>\n```\n\nAnd then instead of using the `--dns-porkbun-key` and `--dns-porkbun-secret` parameters above you can use\n\n```commandline\n...\n--dns-porkbun-credentials </path/to/your/porkbun.ini>\n```\n\nYou can also mix these usages, though the cli parameters always take precedence over the ini file.\n\n#### Examples\n\nBelow are some examples of how to use the plugin.\n\n---\n\nGenerate a certificate with a DNS-01 challenge for the domain `example.org`:\n\n```commandline\ncertbot certonly \\\n  --non-interactive \\\n  --agree-tos \\\n  --email <your-email-address> \\\n  --preferred-challenges dns \\\n  --authenticator dns-porkbun \\\n  --dns-porkbun-key <your-porkbun-api-key> \\\n  --dns-porkbun-secret <your-porkbun-api-secret> \\\n  --dns-porkbun-propagation-seconds 60 \\\n  -d \"example.com\"\n```\n\n---\n\nGenerate a wildcard certificate with a DNS-01 challenge for all subdomains `*.example.com` (Note: the wildcard\ncertificate does not contain the root domain itself):\n\n```commandline\ncertbot certonly \\\n  --non-interactive \\\n  --agree-tos \\\n  --email <your-email-address> \\\n  --preferred-challenges dns \\\n  --authenticator dns-porkbun \\\n  --dns-porkbun-key <your-porkbun-api-key> \\\n  --dns-porkbun-secret <your-porkbun-api-secret> \\\n  --dns-porkbun-propagation-seconds 60 \\\n  -d \"*.example.com\"\n```\n\n---\n\nGenerate a certificate with a DNS-01 challenge for the domain `example.org` using a credentials ini file:\n\n```commandline\ncertbot certonly \\\n  --non-interactive \\\n  --agree-tos \\\n  --email <your-email-address> \\\n  --preferred-challenges dns \\\n  --authenticator dns-porkbun \\\n  --dns-porkbun-credentials </path/to/your/porkbun.ini> \\\n  --dns-porkbun-propagation-seconds 60 \\\n  -d \"example.com\"\n```\n\n---\n\nGenerate a certificate with a DNS-01 challenge for the domain `example.com` without an account (i.e. without an email\naddress):\n\n```commandline\ncertbot certonly \\\n  --non-interactive \\\n  --agree-tos \\\n  --register-unsafely-without-email \\\n  --preferred-challenges dns \\\n  --authenticator dns-porkbun \\\n  --dns-porkbun-key <your-porkbun-api-key> \\\n  --dns-porkbun-secret <your-porkbun-api-secret> \\\n  --dns-porkbun-propagation-seconds 60 \\\n  -d \"example.com\"\n```\n\n---\n\nGenerate a staging certificate (i.e. temporary testing certificate) with a DNS-01 challenge for the\ndomain `example.com`:\n\n```commandline\ncertbot certonly \\\n  --non-interactive \\\n  --agree-tos \\\n  --email <your-email-address> \\\n  --preferred-challenges dns \\\n  --authenticator dns-porkbun \\\n  --dns-porkbun-key <your-porkbun-api-key> \\\n  --dns-porkbun-secret <your-porkbun-api-secret> \\\n  --dns-porkbun-propagation-seconds 60 \\\n  -d \"example.com\" \\\n  --staging\n```\n\n---\n\nThe DNS-01 challenge specification allows to forward the challenge to another domain by CNAME entries and thus to \nperform the validation from another domain.\n\nFor example, we have the domain `example.com` and `mydomain.com`. The nameservers of `example.com` domain are the  \nPorkbun nameserver and `mydomain.com` is somewhere else. \nIn order to perform a DNS-01 challenge for the domain `mydomain.com`, we only need to add this \n`_acme-challenge.mydomain.com` to `_acme-challenge.example.com` CNAME entry in advance:\n\n```commandline\n_acme-challenge.mydomain.com. 600 IN CNAME _acme-challenge.example.com.\n```\n\nThen we can use our Porkbun domain for the actual DNS-01 challenge.\nThe procedure is identical as if we perform a DNS-01 challenge for a Porkbun domain, except that the domain name for \nwhich we perform the challenge is now `mydomain.com` instead of Porkbun's `example.com`.\n\n```commandline\ncertbot certonly \\\n  --non-interactive \\\n  --agree-tos \\\n  --email <your-email-address> \\\n  --preferred-challenges dns \\\n  --authenticator dns-porkbun \\\n  --dns-porkbun-key <your-porkbun-api-key> \\\n  --dns-porkbun-secret <your-porkbun-api-secret> \\\n  --dns-porkbun-propagation-seconds 60 \\\n  -d \"mydomain.com\"\n```\n\nWhat happens in the background is that the CNAME entry is followed to the end and then a TXT entry is created with the \nform `_acme-challenge.example.com.` for the found `example.com` Prokbun domain.\nThus, during the challenge of this example, the DNS would look like this:\n\n```commandline\n_acme-challenge.mydomain.com. 600 IN CNAME _acme-challenge.example.com.\n_acme-challenge.example.com. 60 TXT \"a8sdhb09a7sbd08ashd90ashd90a8hsa9usd\"\n```\n\n---\n\nYou can find al list of all available certbot cli options in\nthe [official documentation](https://certbot.eff.org/docs/using.html#certbot-command-line-options) of _certbot_.\n\n#### Docker\n\nYou can simply start a new container and use the same certbot commands to obtain a new certificate:\n\n```commandline\ndocker run -v \"/etc/letsencrypt:/etc/letsencrypt\" -v \"/var/log/letsencrypt:/var/log/letsencrypt\" infinityofspace/certbot_dns_porkbun:latest \\\n   certonly \\\n     --non-interactive \\\n     --agree-tos \\\n     --email <your-email-address> \\\n     --preferred-challenges dns \\\n     --authenticator dns-porkbun \\\n     --dns-porkbun-key <your-porkbun-api-key> \\\n     --dns-porkbun-secret <your-porkbun-api-secret> \\\n     --dns-porkbun-propagation-seconds 60 \\\n     -d \"example.com\"\n```\n\nOr you can use a credentials file:\n\n```commandline\ndocker run -v \"/etc/letsencrypt:/etc/letsencrypt\" -v \"/var/log/letsencrypt:/var/log/letsencrypt\" -v \"/absolute/path/to/your/porkbun.ini:/conf/porkbun.ini\" infinityofspace/certbot_dns_porkbun:latest \\\n   certonly \\\n     --non-interactive \\\n     --agree-tos \\\n     --email <your-email-address> \\\n     --preferred-challenges dns \\\n     --authenticator dns-porkbun \\\n     --dns-porkbun-credentials /conf/porkbun.ini \\\n     --dns-porkbun-propagation-seconds 60 \\\n     -d \"example.com\"\n```\n\n### Development\n\n#### Setup environment\n\nFirst get the source code:\n\n```commandline\ngit clone https://github.com/infinityofspace/certbot_dns_porkbun.git\ncd certbot_dns_porkbun\n```\n\nNow create a virtual environment, activate it and install all dependencies with the following commands:\n\n```commandline\npython3 -m venv venv\nsource venv/bin/activate\npip3 install -r requirements.txt\n```\n\nNow you can start developing.\n\nFeel free to contribute to this project by creating a pull request.\nBefore you create a pull request, make sure that you code meets the following requirements (you can use the specified\ncommands to check/fulfill the requirements):\n\n- check unit tests: `python -m unittest tests/*.py`\n- format the code: `ruff format`\n- check linting errors:\n```commandline\nflake8 certbot_dns_porkbun --count --ignore E501 --show-source --statistics\npylint certbot_dns_porkbun --disable C0301\n```\n\n#### Tests\n\nYou can run the tests with the following command:\n\n```commandline\npython -m unittest tests/*.py\n```\n\n### Third party notices\n\nAll modules used by this project are listed below:\n\n|                            Name                             |                                                License                                                |\n|:-----------------------------------------------------------:|:-----------------------------------------------------------------------------------------------------:|\n|        [certbot](https://github.com/certbot/certbot)        |          [Apache 2.0](https://raw.githubusercontent.com/certbot/certbot/master/LICENSE.txt)           |\n|      [setuptools](https://github.com/pypa/setuptools)       |                 [MIT](https://raw.githubusercontent.com/pypa/setuptools/main/LICENSE)                 |\n| [pkb_client](https://github.com/infinityofspace/pkb_client) |                [MIT](https://github.com/infinityofspace/pkb_client/blob/main/License)                 |\n|     [dnspython](https://github.com/rthalley/dnspython)      |              [ISC](https://raw.githubusercontent.com/rthalley/dnspython/master/LICENSE)               |\n| [tldextract](https://github.com/john-kurkowski/tldextract)  | [BSD 3-Clause](https://raw.githubusercontent.com/john-kurkowski/tldextract/refs/heads/master/LICENSE) |\n\nFurthermore, this readme file contains embeddings of [Shields.io](https://github.com/badges/shields).\n\n### License\n\n[MIT](https://github.com/infinityofspace/certbot_dns_porkbun/blob/master/License) - Copyright (c) Marvin Heptner\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Plugin for certbot to obtain certificates using a DNS TXT record for Porkbun domains",
    "version": "0.9.1",
    "project_urls": {
        "Homepage": "https://github.com/infinityofspace/certbot_dns_porkbun"
    },
    "split_keywords": [],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "95125498f2b780c57c64c01548296ac2ac45ff32c7b60c8b03c941af67b957ac",
                "md5": "85c5676036e29e0d5578ebab822ae522",
                "sha256": "db3798c7642f5da3dee2975acdc62cc1e891b178cccc51efcd97f566134c43e9"
            },
            "downloads": -1,
            "filename": "certbot_dns_porkbun-0.9.1-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "85c5676036e29e0d5578ebab822ae522",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.9",
            "size": 8770,
            "upload_time": "2024-11-24T21:22:10",
            "upload_time_iso_8601": "2024-11-24T21:22:10.639719Z",
            "url": "https://files.pythonhosted.org/packages/95/12/5498f2b780c57c64c01548296ac2ac45ff32c7b60c8b03c941af67b957ac/certbot_dns_porkbun-0.9.1-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "d6516cae36eba174488c819f77b3bc25b582545df5099bb7108f02665be64603",
                "md5": "3f5516bc16ee07e69fb6ac617a598c29",
                "sha256": "7e2d3242d2edb676e1b3a4b2caf1f90b9486bb4dc3a9f2b2ec2b9d9c4a5b8185"
            },
            "downloads": -1,
            "filename": "certbot_dns_porkbun-0.9.1.tar.gz",
            "has_sig": false,
            "md5_digest": "3f5516bc16ee07e69fb6ac617a598c29",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.9",
            "size": 7790,
            "upload_time": "2024-11-24T21:22:12",
            "upload_time_iso_8601": "2024-11-24T21:22:12.377715Z",
            "url": "https://files.pythonhosted.org/packages/d6/51/6cae36eba174488c819f77b3bc25b582545df5099bb7108f02665be64603/certbot_dns_porkbun-0.9.1.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-11-24 21:22:12",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "infinityofspace",
    "github_project": "certbot_dns_porkbun",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "requirements": [
        {
            "name": "setuptools",
            "specs": [
                [
                    ">=",
                    "41.6.0"
                ]
            ]
        },
        {
            "name": "certbot",
            "specs": [
                [
                    ">=",
                    "1.18.0"
                ],
                [
                    "<",
                    "4.0"
                ]
            ]
        },
        {
            "name": "pkb_client",
            "specs": [
                [
                    "<",
                    "3.0"
                ],
                [
                    ">=",
                    "2.0"
                ]
            ]
        },
        {
            "name": "dnspython",
            "specs": [
                [
                    "<",
                    "3.0"
                ],
                [
                    ">=",
                    "2.0.0"
                ]
            ]
        },
        {
            "name": "tldextract",
            "specs": [
                [
                    "<",
                    "6.0"
                ],
                [
                    ">=",
                    "5.1.2"
                ]
            ]
        }
    ],
    "lcname": "certbot-dns-porkbun"
}
        
Elapsed time: 0.79861s