Back to Lego

Yandex Cloud

docs/content/dns/zz_gen_yandexcloud.md

4.35.22.6 KB
Original Source
<!-- THIS DOCUMENTATION IS AUTO-GENERATED. PLEASE DO NOT EDIT. --> <!-- providers/dns/yandexcloud/yandexcloud.toml --> <!-- THIS DOCUMENTATION IS AUTO-GENERATED. PLEASE DO NOT EDIT. -->

Configuration for Yandex Cloud.

<!--more-->
  • Code: yandexcloud
  • Since: v4.9.0

Here is an example bash command using the Yandex Cloud provider:

bash
YANDEX_CLOUD_IAM_TOKEN=<base64_IAM_token> \
YANDEX_CLOUD_FOLDER_ID=<folder/project_id> \
lego --dns yandexcloud -d '*.example.com' -d example.com run

# ---

YANDEX_CLOUD_IAM_TOKEN=$(echo '{ \
  "id": "<string id>", \
  "service_account_id": "<string id>", \
  "created_at": "<datetime>", \
  "key_algorithm": "RSA_2048", \
  "public_key": "-----BEGIN PUBLIC KEY-----<rsa public key>-----END PUBLIC KEY-----", \
  "private_key": "-----BEGIN PRIVATE KEY-----<rsa private key>-----END PRIVATE KEY-----" \
}' | base64) \
YANDEX_CLOUD_FOLDER_ID=<yandex cloud folder(project) id> \
lego --dns yandexcloud -d '*.example.com' -d example.com run

Credentials

Environment Variable NameDescription
YANDEX_CLOUD_FOLDER_IDThe string id of folder (aka project) in Yandex Cloud
YANDEX_CLOUD_IAM_TOKENThe base64 encoded json which contains information about iam token of service account with dns.admin permissions

The environment variable names can be suffixed by _FILE to reference a file instead of a value. More information [here]({{% ref "dns#configuration-and-credentials" %}}).

Additional Configuration

Environment Variable NameDescription
YANDEX_CLOUD_POLLING_INTERVALTime between DNS propagation check in seconds (Default: 2)
YANDEX_CLOUD_PROPAGATION_TIMEOUTMaximum waiting time for DNS propagation in seconds (Default: 60)
YANDEX_CLOUD_TTLThe TTL of the TXT record used for the DNS challenge in seconds (Default: 60)

The environment variable names can be suffixed by _FILE to reference a file instead of a value. More information [here]({{% ref "dns#configuration-and-credentials" %}}).

IAM Token

The simplest way to retrieve IAM access token is usage of yc-cli, follow docs to get it

bash
yc iam key create --service-account-name my-robot --output key.json
cat key.json | base64

More information

<!-- THIS DOCUMENTATION IS AUTO-GENERATED. PLEASE DO NOT EDIT. --> <!-- providers/dns/yandexcloud/yandexcloud.toml --> <!-- THIS DOCUMENTATION IS AUTO-GENERATED. PLEASE DO NOT EDIT. -->