Skip to main content

Infomaniak DNS Authenticator plugin for certbot

This plugin enables usage of Infomaniak public API to complete dns-01 challenges.

Issue a token

At your Infomaniak manager dashboard, go to the API section and generate a token with dns:read and dns:write scopes.

Installation

pip install certbot-dns-infomaniak

Usage

Via environment variable

export INFOMANIAK_API_TOKEN=xxx
certbot certonly \
  --authenticator dns-infomaniak \
  --server https://acme-v02.api.letsencrypt.org/directory \
  --agree-tos \
  --rsa-key-size 4096 \
  -d 'death.star'

If certbot requires elevated rights, the following command must be used instead:

export INFOMANIAK_API_TOKEN=xxx
sudo --preserve-env=INFOMANIAK_API_TOKEN certbot certonly \
  --authenticator dns-infomaniak \
  --server https://acme-v02.api.letsencrypt.org/directory \
  --agree-tos \
  --rsa-key-size 4096 \
  -d 'death.star'

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-infomaniak

select the authenticator plugin (Required)

--dns-infomaniak-credentials

Infomaniak Token credentials INI file. (Required)

An example credentials.ini file:

dns_infomaniak_token = XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

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

certbot certonly \
  --authenticator dns-infomaniak \
  --dns-infomaniak-credentials <path to file> \
  --server https://acme-v02.api.letsencrypt.org/directory \
  --agree-tos \
  --rsa-key-size 4096 \
  -d 'death.star'

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="INFOMANIAK_API_TOKEN=<YOUR_API_TOKEN>"

Local Development

Usage of uv to manage virtual environments and dependencies as defined in pyproject.toml is strongly recommended.

Simply run uv sync to automatically create or update the .venv. Usual activation is not required as all tools can simply be run within the project’s environment through uv run..., (eg. uv run ruff check, uv run pytest), eliminating the need for manual requirements management.

Acknowledgments

Based on certbot-dns-ispconfig plugin at https://github.com/m42e/certbot-dns-ispconfig/

Download files

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

Source Distribution

certbot_dns_infomaniak-0.3.1.tar.gz (6.1 kB view details)

Uploaded Source

Built Distribution

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

certbot_dns_infomaniak-0.3.1-py3-none-any.whl (7.9 kB view details)

Uploaded Python 3

File details

Details for the file certbot_dns_infomaniak-0.3.1.tar.gz.

File metadata

  • Download URL: certbot_dns_infomaniak-0.3.1.tar.gz
  • Upload date:
  • Size: 6.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.12.3 {"installer":{"name":"uv","version":"0.12.3","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for certbot_dns_infomaniak-0.3.1.tar.gz
Algorithm Hash digest
SHA256 cf4e3eda37371e9622324a5a0314062797ba58af9da05ab0be4034844d748d6e
MD5 30a42b519f6cfe2758155b6accac2c6c
BLAKE2b-256 86fbaac9a74c586fbc85d1dd0b0b1c658161495eb2747653fb868778a6c6ad14

See more details on using hashes here.

File details

Details for the file certbot_dns_infomaniak-0.3.1-py3-none-any.whl.

File metadata

  • Download URL: certbot_dns_infomaniak-0.3.1-py3-none-any.whl
  • Upload date:
  • Size: 7.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.12.3 {"installer":{"name":"uv","version":"0.12.3","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for certbot_dns_infomaniak-0.3.1-py3-none-any.whl
Algorithm Hash digest
SHA256 164e81639438f546943b5476ea598417540bd9991cf174558e518ce6e5498ec3
MD5 579eee69c299c765e731017ca341d3ae
BLAKE2b-256 04bb9a89d8a5936fc69123ed93bbda8c6ae445811d7f668fee5f3dfa6ebd93a8

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 Sentry Error logging StatusPage Status page