Skip to content

Commit

Permalink
Add desec.io support to letsencrypt (#3157)
Browse files Browse the repository at this point in the history
  • Loading branch information
henrikhierl authored Dec 4, 2023
1 parent d83ee07 commit 622e980
Show file tree
Hide file tree
Showing 7 changed files with 18 additions and 3 deletions.
4 changes: 4 additions & 0 deletions letsencrypt/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Changelog

## 5.0.3

- Add deSEC DNS challenge support

## 5.0.2

- Fix DirectAdmin DNS challenge support
Expand Down
2 changes: 2 additions & 0 deletions letsencrypt/DOCS.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ azure_config: ''
cloudflare_email: ''
cloudflare_api_key: ''
cloudflare_api_token: ''
desec_token: ''
digitalocean_token: ''
directadmin_url: ''
directadmin_username: ''
Expand Down Expand Up @@ -524,6 +525,7 @@ You can in addition find the files via the "samba" addon within the "ssl" share.
```txt
dns-azure
dns-cloudflare
dns-desec
dns-digitalocean
dns-directadmin
dns-dnsimple
Expand Down
2 changes: 2 additions & 0 deletions letsencrypt/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ ARG \
CRYPTOGRAPHY_VERSION \
CERTBOT_VERSION \
CERTBOT_DNS_AZURE_VERSION \
CERTBOT_DNS_DESEC_VERSION \
CERTBOT_DNS_DIRECTADMIN_VERSION \
CERTBOT_DNS_DUCKDNS_VERSION \
CERTBOT_DNS_GOOGLE_DOMAINS_VERSION \
Expand Down Expand Up @@ -36,6 +37,7 @@ RUN \
certbot==${CERTBOT_VERSION} \
certbot-dns-azure==${CERTBOT_DNS_AZURE_VERSION} \
certbot-dns-cloudflare==${CERTBOT_VERSION} \
certbot-dns-desec==${CERTBOT_DNS_DESEC_VERSION} \
certbot-dns-digitalocean==${CERTBOT_VERSION} \
certbot-dns-directadmin==${CERTBOT_DNS_DIRECTADMIN_VERSION} \
certbot-dns-dnsimple==${CERTBOT_VERSION} \
Expand Down
1 change: 1 addition & 0 deletions letsencrypt/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ codenotary:
args:
CRYPTOGRAPHY_VERSION: 41.0.5
CERTBOT_DNS_AZURE_VERSION: 2.4.0
CERTBOT_DNS_DESEC_VERSION: 1.2.1
CERTBOT_DNS_DIRECTADMIN_VERSION: 1.0.3
CERTBOT_DNS_DUCKDNS_VERSION: 1.3
CERTBOT_DNS_HETZNER_VERSION: 2.0.0
Expand Down
5 changes: 3 additions & 2 deletions letsencrypt/config.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
version: 5.0.2
version: 5.0.3
slug: letsencrypt
name: Let's Encrypt
description: Manage certificate from Let's Encrypt
Expand Down Expand Up @@ -42,6 +42,7 @@ schema:
cloudflare_api_key: str?
cloudflare_api_token: str?
cloudflare_email: email?
desec_token: str?
digitalocean_token: str?
directadmin_password: str?
directadmin_url: str?
Expand Down Expand Up @@ -72,7 +73,7 @@ schema:
ovh_consumer_key: str?
ovh_endpoint: str?
propagation_seconds: int(60,3600)?
provider: "list(dns-azure|dns-cloudflare|dns-digitalocean|\
provider: "list(dns-azure|dns-cloudflare|dns-desec|dns-digitalocean|\
dns-directadmin|dns-dnsimple|dns-dnsmadeeasy|dns-duckdns|\
dns-gehirn|dns-google|dns-google-domains|\
dns-hetzner|dns-linode|dns-luadns|dns-njalla|dns-nsone|dns-ovh|\
Expand Down
3 changes: 2 additions & 1 deletion letsencrypt/rootfs/etc/cont-init.d/file-structure.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@ mkdir -p /data/workdir
mkdir -p /data/letsencrypt

# Setup Let's encrypt config
echo -e "dns_digitalocean_token = $(bashio::config 'dns.digitalocean_token')\n" \
echo -e "dns_desec_token = $(bashio::config 'dns.desec_token')\n" \
"dns_digitalocean_token = $(bashio::config 'dns.digitalocean_token')\n" \
"directadmin_url = $(bashio::config 'dns.directadmin_url')\n" \
"directadmin_username = $(bashio::config 'dns.directadmin_username')\n" \
"directadmin_password = $(bashio::config 'dns.directadmin_password')\n" \
Expand Down
4 changes: 4 additions & 0 deletions letsencrypt/rootfs/etc/services.d/lets-encrypt/run
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,10 @@ elif [ "${CHALLENGE}" == "dns" ] && [ "${DNS_PROVIDER}" == "dns-inwx" ]; then
bashio::config.require 'dns.inwx_shared_secret'
PROVIDER_ARGUMENTS+=("-v" "--authenticator" "${DNS_PROVIDER}" "--dns-inwx-credentials" "/data/dnsapikey" "--dns-inwx-propagation-seconds" "${PROPAGATION_SECONDS}")

elif [ "${CHALLENGE}" == "dns" ] && [ "${DNS_PROVIDER}" == "dns-desec" ]; then
bashio::config.require 'dns.desec_token'
PROVIDER_ARGUMENTS+=("--authenticator" "${DNS_PROVIDER}" "--${DNS_PROVIDER}-credentials" "/data/dnsapikey" "--${DNS_PROVIDER}-propagation-seconds" "${PROPAGATION_SECONDS}")

#All others
else
PROVIDER_ARGUMENTS+=("--${DNS_PROVIDER}" "--${DNS_PROVIDER}-credentials" "/data/dnsapikey")
Expand Down

0 comments on commit 622e980

Please sign in to comment.