From a3d86b7d8d12c02e701ba102263b36cc375127bb Mon Sep 17 00:00:00 2001 From: troykelly Date: Wed, 22 Jan 2025 04:57:56 +0000 Subject: [PATCH 1/5] Prettified Code! --- .devcontainer/devcontainer.json | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json index 659360a..843b350 100644 --- a/.devcontainer/devcontainer.json +++ b/.devcontainer/devcontainer.json @@ -14,15 +14,15 @@ "nonFreePackages": true, "username": "vscode", "userUid": "automatic", - "userGid": "automatic", + "userGid": "automatic" }, "ghcr.io/devcontainers-contrib/features/zsh-plugins:0": { "plugins": "ssh-agent npm", "omzPlugins": "https://github.com/zsh-users/zsh-autosuggestions", - "username": "vscode", + "username": "vscode" }, - "ghcr.io/stuartleeks/dev-container-features/shell-history:0": {}, - }, + "ghcr.io/stuartleeks/dev-container-features/shell-history:0": {} + } // Features to add to the dev container. More info: https://containers.dev/features. // "features": {}, From ea16b3668a3571961ded6e7210992c5af325391e Mon Sep 17 00:00:00 2001 From: Troy Kelly Date: Wed, 22 Jan 2025 15:57:56 +1100 Subject: [PATCH 2/5] Update build.yaml --- letslexicon/build.yaml | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/letslexicon/build.yaml b/letslexicon/build.yaml index 728aa51..3768e96 100644 --- a/letslexicon/build.yaml +++ b/letslexicon/build.yaml @@ -1,14 +1,14 @@ --- build_from: - aarch64: ghcr.io/hassio-addons/base-python/aarch64:12.0.2 - amd64: ghcr.io/hassio-addons/base-python/amd64:12.0.2 - armhf: ghcr.io/hassio-addons/base-python/armhf:12.0.2 - armv7: ghcr.io/hassio-addons/base-python/armv7:12.0.2 - i386: ghcr.io/hassio-addons/base-python/i386:12.0.2 + aarch64: ghcr.io/hassio-addons/base-python/aarch64:16.0.1 + amd64: ghcr.io/hassio-addons/base-python/amd64:16.0.1 + armhf: ghcr.io/hassio-addons/base-python/armhf:16.0.1 + armv7: ghcr.io/hassio-addons/base-python/armv7:16.0.1 + i386: ghcr.io/hassio-addons/base-python/i386:16.0.1 codenotary: base_image: codenotary@frenck.dev signer: codenotary@frenck.dev args: DEHYDRATED_VERSION: v0.7.1 - LEXICON_VERSION: 3.17.0 - PIP_VERSION: 23.3.1 + LEXICON_VERSION: 3.20.1 + PIP_VERSION: 24.3.1 From dd6f699fd2f6bb6edea177525a7092a903209512 Mon Sep 17 00:00:00 2001 From: Troy Kelly Date: Wed, 22 Jan 2025 16:17:21 +1100 Subject: [PATCH 3/5] Update Dockerfile --- letslexicon/Dockerfile | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/letslexicon/Dockerfile b/letslexicon/Dockerfile index 9bb50ba..40b2aca 100644 --- a/letslexicon/Dockerfile +++ b/letslexicon/Dockerfile @@ -7,25 +7,25 @@ COPY rootfs / ARG DEHYDRATED_VERSION=v0.7.1 ARG LEXICON_VERSION=3.17.0 -ARG PIP_VERSION=23.3.1 +ARG PIP_VERSION=24.3.1 # Setup base # hadolint ignore=SC2102 RUN apk add --no-cache \ - coreutils=9.3-r1 \ - libffi=3.4.4-r2 \ - musl=1.2.4-r2 \ - openssl=3.1.4-r1 \ + coreutils=9.5-r2 \ + libffi=3.4.6-r0 \ + musl=1.2.5-r8 \ + openssl=3.3.2-r4 \ sed=4.9-r2 \ - wget=1.21.4-r0 && \ + wget=1.25.0-r0 && \ apk add --no-cache --virtual .build-dependencies \ - g++=12.2.1_git20220924-r10 \ - git=2.40.1-r0 \ - libffi-dev=3.4.4-r2 \ - libxml2-dev=2.11.6-r0 \ - libxslt-dev=1.1.38-r0 \ - musl-dev=1.2.4-r2 \ - openssl-dev=3.1.4-r1 && \ + g++=14.2.0-r4 \ + git=2.47.2-r0 \ + libffi-dev=3.4.6-r0 \ + libxml2-dev=2.13.4-r3 \ + libxslt-dev=1.1.42-r1 \ + musl-dev=1.2.5-r8 \ + openssl-dev=3.3.2-r4 && \ pip install --no-cache-dir --upgrade pip==${PIP_VERSION} && \ pip3 install --no-cache-dir dns-lexicon[full]==${LEXICON_VERSION} && \ mkdir -p /opt /var/www/dehydrated && \ From 96b086a23bb35d28e7d66062e2c7f85c6b3554f8 Mon Sep 17 00:00:00 2001 From: Troy Kelly Date: Wed, 22 Jan 2025 16:22:00 +1100 Subject: [PATCH 4/5] Update README.md --- README.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 4e914ce..0219ceb 100644 --- a/README.md +++ b/README.md @@ -967,7 +967,7 @@ In case you've found a bug, please [open an issue on our GitHub][issue]. [forum]: https://community.home-assistant.io [issue]: https://github.com/troykelly/hassio-addons-letsencrypt-lexicon/issues [certbot]: https://certbot.eff.org -[source-shield]: https://img.shields.io/badge/version-v0.7.0-blue.svg -[source]: https://github.com/lukas2511/dehydrated/releases/tag/v0.7.0 -[lexicon-shield]: https://img.shields.io/badge/lexicon-v3.11.4-blue.svg -[lexicon]: https://github.com/AnalogJ/lexicon/releases/tag/v3.11.4 +[source-shield]: https://img.shields.io/badge/version-v0.7.1-blue.svg +[source]: https://github.com/lukas2511/dehydrated/releases/tag/v0.7.1 +[lexicon-shield]: https://img.shields.io/badge/lexicon-v3.20.1-blue.svg +[lexicon]: https://github.com/AnalogJ/lexicon/releases/tag/v3.20.1 From 9163b6e404118c5485748f5f8665a63b4a690bec Mon Sep 17 00:00:00 2001 From: Troy Kelly Date: Wed, 22 Jan 2025 16:47:33 +1100 Subject: [PATCH 5/5] Updating config and script --- letslexicon/config.yaml | 7 ++++- letslexicon/rootfs/usr/bin/certificates | 37 +++++++++++++++++++++++++ providers.txt | 16 ++++++++++- 3 files changed, 58 insertions(+), 2 deletions(-) diff --git a/letslexicon/config.yaml b/letslexicon/config.yaml index b6de34c..1cf7d6e 100644 --- a/letslexicon/config.yaml +++ b/letslexicon/config.yaml @@ -32,7 +32,7 @@ schema: keyfile: str dns: provider: list( - aliyun|aurora|azure|cloudflare|cloudns|cloudxns|conoha|constellix|ddns|digitalocean|dinahosting|directadmin|dnsimple|dnsmadeeasy|dnspark|dnspod|dnsservices|dreamhost|duckdns|dynu|easydns|easyname|euserv|exoscale|flexibleengine|gandi|gehirn|glesys|godaddy|googleclouddns|gransy|gratisdns|henet|hetzner|hostingde|hover|infoblox|infomaniak|internetbs|inwx|joker|linode|linode4|localzone|luadns|memset|misaka|mythicbeasts|namecheap|namecom|namesilo|netcup|nfsn|njalla|nsone|oci|onapp|online|ovh|plesk|pointhq|porkbun|powerdns|rackspace|rage4|rcodezero|route53|safedns|sakuracloud|softlayer|transip|ultradns|valuedomain|vercel|vultr|webgo|wedos|yandex|yandexcloud|zeit|zilore|zonomi)? + aliyun|aurora|azure|cloudflare|cloudns|cloudxns|conoha|constellix|ddns|digitalocean|dinahosting|directadmin|dnsimple|dnsmadeeasy|dnspark|dnspod|dnsservices|dreamhost|duckdns|dynu|easydns|easyname|euserv|exoscale|flexibleengine|gandi|gehirn|glesys|godaddy|googleclouddns|gransy|gratisdns|henet|hetzner|hostingde|hover|infoblox|infomaniak|internetbs|inwx|ionos|joker|linode|linode4|localzone|luadns|memset|misaka|mythicbeasts|namecheap|namecom|namesilo|netcup|nfsn|njalla|nsone|oci|onapp|online|ovh|plesk|pointhq|porkbun|powerdns|qcloud|rackspace|rage4|rcodezero|regfish|route53|safedns|sakuracloud|softlayer|timeweb|transip|ultradns|valuedomain|vercel|vultr|webgo|wedos|yandex|yandexcloud|zeit|zilore|zonomi)? # Provider specific options aliyun_auth_key_id: str? aliyun_auth_secret: str? @@ -122,6 +122,7 @@ schema: internetbs_auth_password: str? inwx_auth_password: str? inwx_auth_username: str? + ionos_api_key: str? joker_auth_token: str? linode_auth_token: str? linode4_auth_token: str? @@ -176,6 +177,8 @@ schema: powerdns_pdns_disable_notify: str? powerdns_pdns_server: str? powerdns_pdns_server_id: str? + qcloud_secret_id: str? + qcloud_secret_key: str? rackspace_auth_account: str? rackspace_auth_api_key: str? rackspace_auth_token: str? @@ -184,6 +187,7 @@ schema: rage4_auth_token: str? rage4_auth_username: str? rcodezero_auth_token: str? + regfish_auth_api_key: str? route53_auth_access_key: str? route53_auth_access_secret: str? route53_auth_token: str? @@ -195,6 +199,7 @@ schema: sakuracloud_auth_token: str? softlayer_auth_api_key: str? softlayer_auth_username: str? + timeweb_auth_token: str? transip_auth_api_key: str? transip_auth_key_is_global: str? transip_auth_username: str? diff --git a/letslexicon/rootfs/usr/bin/certificates b/letslexicon/rootfs/usr/bin/certificates index b82ce66..01004a1 100755 --- a/letslexicon/rootfs/usr/bin/certificates +++ b/letslexicon/rootfs/usr/bin/certificates @@ -69,6 +69,7 @@ infoblox infomaniak internetbs inwx +ionos joker linode linode4 @@ -92,13 +93,16 @@ plesk pointhq porkbun powerdns +qcloud rackspace rage4 rcodezero +regfish route53 safedns sakuracloud softlayer +timeweb transip ultradns valuedomain @@ -710,6 +714,13 @@ refresh_certificates() { bashio::log.info "Set inwx_auth_username" fi +# ionos + if bashio::config.has_value 'dns.ionos_api_key'; then + LEXICON_IONOS_API_KEY=$(bashio::config 'dns.ionos_api_key') + export LEXICON_IONOS_API_KEY + bashio::log.info "Set ionos_api_key" + fi + # joker if bashio::config.has_value 'dns.joker_auth_token'; then LEXICON_JOKER_AUTH_TOKEN=$(bashio::config 'dns.joker_auth_token') @@ -1026,6 +1037,18 @@ refresh_certificates() { bashio::log.info "Set powerdns_pdns_server_id" fi +# qcloud + if bashio::config.has_value 'dns.qcloud_secret_id'; then + LEXICON_QCLOUD_SECRET_ID=$(bashio::config 'dns.qcloud_secret_id') + export LEXICON_QCLOUD_SECRET_ID + bashio::log.info "Set qcloud_secret_id" + fi + if bashio::config.has_value 'dns.qcloud_secret_key'; then + LEXICON_QCLOUD_SECRET_KEY=$(bashio::config 'dns.qcloud_secret_key') + export LEXICON_QCLOUD_SECRET_KEY + bashio::log.info "Set qcloud_secret_key" + fi + # rackspace if bashio::config.has_value 'dns.rackspace_auth_account'; then LEXICON_RACKSPACE_AUTH_ACCOUNT=$(bashio::config 'dns.rackspace_auth_account') @@ -1072,6 +1095,13 @@ refresh_certificates() { bashio::log.info "Set rcodezero_auth_token" fi +# regfish + if bashio::config.has_value 'dns.regfish_auth_api_key'; then + LEXICON_REGFISH_AUTH_API_KEY=$(bashio::config 'dns.regfish_auth_api_key') + export LEXICON_REGFISH_AUTH_API_KEY + bashio::log.info "Set regfish_auth_api_key" + fi + # route53 if bashio::config.has_value 'dns.route53_auth_access_key'; then LEXICON_ROUTE53_AUTH_ACCESS_KEY=$(bashio::config 'dns.route53_auth_access_key') @@ -1135,6 +1165,13 @@ refresh_certificates() { bashio::log.info "Set softlayer_auth_username" fi +# timeweb + if bashio::config.has_value 'dns.timeweb_auth_token'; then + LEXICON_TIMEWEB_AUTH_TOKEN=$(bashio::config 'dns.timeweb_auth_token') + export LEXICON_TIMEWEB_AUTH_TOKEN + bashio::log.info "Set timeweb_auth_token" + fi + # transip if bashio::config.has_value 'dns.transip_auth_api_key'; then LEXICON_TRANSIP_AUTH_API_KEY=$(bashio::config 'dns.transip_auth_api_key') diff --git a/providers.txt b/providers.txt index 7a63a3b..4efd229 100644 --- a/providers.txt +++ b/providers.txt @@ -144,7 +144,7 @@ auth_token Specify token for authentication zone_id Specify the zone id gandi -auth_token Specify gandi api key +auth_token Specify gandi api key or personal access token api_protocol (optional) specify gandi api protocol to use: rpc (default) or rest @@ -216,6 +216,9 @@ auth_username Specify username for authentication auth_password Specify password for authentication +ionos +api_key Ionos api key: public prefix + period + key proper + joker auth_token Specify the api key to connect to the joker.com api @@ -347,6 +350,11 @@ pdns_server_id Server id to interact with pdns_disable_notify Disable slave notifications from master +qcloud +secret_id Specify secret_id for authentication + +secret_key Specify secret_key for authentication + rackspace auth_account Specify account number for authentication @@ -366,6 +374,9 @@ auth_token Specify token for authentication rcodezero auth_token Specify token for authentication +regfish +auth_api_key Specify api key for authentication + route53 auth_access_key Specify access_key for authentication @@ -392,6 +403,9 @@ auth_username Specify username for authentication auth_api_key Specify api private key for authentication +timeweb +auth_token Specify api token for authentication + transip auth_username Specify username for authentication