mirror of
https://github.com/netbirdio/plugins.git
synced 2026-05-22 18:44:07 -07:00
www/caddy: DNS Provider add netcup and RFC2136 (#3998)
* Add configuration options for DNS Providers: Netcup and RFC2136 * Bump plugin version and description.
This commit is contained in:
+1
-2
@@ -1,6 +1,5 @@
|
||||
PLUGIN_NAME= caddy
|
||||
PLUGIN_VERSION= 1.5.5
|
||||
PLUGIN_REVISION= 1
|
||||
PLUGIN_VERSION= 1.5.6
|
||||
PLUGIN_DEPENDS= caddy-custom
|
||||
PLUGIN_COMMENT= Easy to configure Reverse Proxy with Automatic HTTPS and Dynamic DNS
|
||||
PLUGIN_MAINTAINER= cedrik@pischem.com
|
||||
|
||||
@@ -29,6 +29,7 @@ Plugin Changelog
|
||||
1.5.6
|
||||
|
||||
* Fix: Wildcard domains with activated "Dynamic DNS" update their base domain with * instead of @.
|
||||
* Add: DNS Providers: Netcup, RFC2136
|
||||
|
||||
1.5.5
|
||||
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
<id>caddy.general.TlsDnsApiKey</id>
|
||||
<label>DNS API Standard Field</label>
|
||||
<type>text</type>
|
||||
<help><![CDATA[This is the standard field for the API Key. Field can be left empty if optional: Cloudflare "api_token", Duckdns "api_token", DigitalOcean "auth_token", Godaddy "api_token", Gandi "bearer_token", IONOS "api_token", deSEC "token", Route53 "access_key_id", Porkbun "api_key", ACME-DNS "username", Netlify "personal_access_token", Njalla "api_token", Google Cloud DNS "gcp_project", Azure "tenant_id", OVH "endpoint", Namecheap "api_key", PowerDNS "server_url", DDNSS "api_token", Linode "api_token", Tencent Cloud "secret_id", Dinahosting "username", Hexonet "username", Mail-in-a-Box "api_url".]]></help>
|
||||
<help><![CDATA[This is the standard field for the API Key. Field can be left empty if optional: Cloudflare "api_token", Duckdns "api_token", DigitalOcean "auth_token", Godaddy "api_token", Gandi "bearer_token", IONOS "api_token", deSEC "token", Route53 "access_key_id", Porkbun "api_key", ACME-DNS "username", Netlify "personal_access_token", Njalla "api_token", Google Cloud DNS "gcp_project", Azure "tenant_id", OVH "endpoint", Namecheap "api_key", PowerDNS "server_url", DDNSS "api_token", Linode "api_token", Tencent Cloud "secret_id", Dinahosting "username", Hexonet "username", Mail-in-a-Box "api_url", Netcup "customer_number", RFC2136 "key_name".]]></help>
|
||||
</field>
|
||||
<field>
|
||||
<type>header</type>
|
||||
@@ -20,19 +20,19 @@
|
||||
<id>caddy.general.TlsDnsSecretApiKey</id>
|
||||
<label>DNS API Additional Field 1</label>
|
||||
<type>text</type>
|
||||
<help><![CDATA[Leave empty if your DNS Provider isn't specified here. Field can be left empty if optional: Duckdns "override_domain", Route53 "secret_access_key", Porkbun "api_secret_key", ACME-DNS "password", Azure "client_id", OVH "application_key", Namecheap "user", PowerDNS "api_token", DDNSS "username", Linode "api_url", Tencent Cloud "secret_key", Dinahosting "password", Hexonet "password", Mail-in-a-Box "email_address".]]></help>
|
||||
<help><![CDATA[Leave empty if your DNS Provider isn't specified here. Field can be left empty if optional: Duckdns "override_domain", Route53 "secret_access_key", Porkbun "api_secret_key", ACME-DNS "password", Azure "client_id", OVH "application_key", Namecheap "user", PowerDNS "api_token", DDNSS "username", Linode "api_url", Tencent Cloud "secret_key", Dinahosting "password", Hexonet "password", Mail-in-a-Box "email_address", Netcup "api_key", RFC2136 "key_alg".]]></help>
|
||||
</field>
|
||||
<field>
|
||||
<id>caddy.general.TlsDnsOptionalField1</id>
|
||||
<label>DNS API Additional Field 2</label>
|
||||
<type>text</type>
|
||||
<help><![CDATA[Leave empty if your DNS Provider isn't specified here. Field can be left empty if optional: Route53 "max_retries", ACME-DNS "subdomain", Azure "client_secret", OVH "application_secret", Namecheap "api_endpoint", DDNSS "password", Linode "api_version", Mail-in-a-Box "password".]]></help>
|
||||
<help><![CDATA[Leave empty if your DNS Provider isn't specified here. Field can be left empty if optional: Route53 "max_retries", ACME-DNS "subdomain", Azure "client_secret", OVH "application_secret", Namecheap "api_endpoint", DDNSS "password", Linode "api_version", Mail-in-a-Box "password", Netcup "api_password", RFC2136 "key".]]></help>
|
||||
</field>
|
||||
<field>
|
||||
<id>caddy.general.TlsDnsOptionalField2</id>
|
||||
<label>DNS API Additional Field 3</label>
|
||||
<type>text</type>
|
||||
<help><![CDATA[Leave empty if your DNS Provider isn't specified here. Field can be left empty if optional: Route53 "aws_profile", ACME-DNS "server_url", Azure "subscription_id", OVH "consumer_key", Namecheap "client_ip", DDNS "password".]]></help>
|
||||
<help><![CDATA[Leave empty if your DNS Provider isn't specified here. Field can be left empty if optional: Route53 "aws_profile", ACME-DNS "server_url", Azure "subscription_id", OVH "consumer_key", Namecheap "client_ip", DDNS "password", RFC2136 "server".]]></help>
|
||||
</field>
|
||||
<field>
|
||||
<id>caddy.general.TlsDnsOptionalField3</id>
|
||||
|
||||
@@ -46,6 +46,8 @@
|
||||
<dinahosting>Dinahosting</dinahosting>
|
||||
<hexonet>Hexonet</hexonet>
|
||||
<mailinabox>Mail-in-a-Box</mailinabox>
|
||||
<netcup>Netcup</netcup>
|
||||
<rfc2136>RFC2136</rfc2136>
|
||||
</OptionValues>
|
||||
</TlsDnsProvider>
|
||||
<TlsDnsApiKey type="TextField"/>
|
||||
|
||||
@@ -143,7 +143,7 @@
|
||||
|
||||
{% if dnsProvider and dnsProvider != "acmedns" and dynDnsDomains|length > 0 %}
|
||||
dynamic_dns {
|
||||
{% if dnsProvider in ['porkbun', 'desec', 'route53', 'googleclouddns', 'azure', 'ovh', 'namecheap', 'powerdns', 'ddnss', 'linode', 'tencentcloud', 'dinahosting', 'hexonet', 'mailinabox'] %}
|
||||
{% if dnsProvider in ['porkbun', 'desec', 'route53', 'googleclouddns', 'azure', 'ovh', 'namecheap', 'powerdns', 'ddnss', 'linode', 'tencentcloud', 'dinahosting', 'hexonet', 'mailinabox', 'netcup', 'rfc2136'] %}
|
||||
provider {{ dnsProvider }} {
|
||||
{% if dnsProvider == 'porkbun' %}
|
||||
{% if dnsApiKey %}api_key {{ dnsApiKey }}
|
||||
@@ -238,6 +238,22 @@
|
||||
{% endif %}
|
||||
{% if dnsOptionalField1 %}password {{ dnsOptionalField1 }}
|
||||
{% endif %}
|
||||
{% elif dnsProvider == 'netcup' %}
|
||||
{% if dnsApiKey %}customer_number {{ dnsApiKey }}
|
||||
{% endif %}
|
||||
{% if dnsSecretApiKey %}api_key {{ dnsSecretApiKey }}
|
||||
{% endif %}
|
||||
{% if dnsOptionalField1 %}api_password {{ dnsOptionalField1 }}
|
||||
{% endif %}
|
||||
{% elif dnsProvider == 'rfc2136' %}
|
||||
{% if dnsApiKey %}key_name {{ dnsApiKey }}
|
||||
{% endif %}
|
||||
{% if dnsSecretApiKey %}key_alg {{ dnsSecretApiKey }}
|
||||
{% endif %}
|
||||
{% if dnsOptionalField1 %}key {{ dnsOptionalField1 }}
|
||||
{% endif %}
|
||||
{% if dnsOptionalField2 %}server {{ dnsOptionalField2 }}
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
}
|
||||
{% else %}
|
||||
@@ -342,7 +358,7 @@
|
||||
#}
|
||||
{% macro tls_configuration(dnsProvider, dnsApiKey, customCert, dnsChallenge, dnsSecretApiKey, TlsDnsOptionalField1, TlsDnsOptionalField2, TlsDnsOptionalField3, TlsDnsOptionalField4) %}
|
||||
{% if dnsChallenge == "1" and dnsProvider %}
|
||||
{% if dnsProvider in ['duckdns', 'porkbun', 'desec', 'route53', 'acmedns', 'googleclouddns', 'azure', 'ovh', 'namecheap', 'powerdns', 'ddnss', 'linode', 'tencentcloud', 'dinahosting', 'hexonet', 'mailinabox'] %}
|
||||
{% if dnsProvider in ['duckdns', 'porkbun', 'desec', 'route53', 'acmedns', 'googleclouddns', 'azure', 'ovh', 'namecheap', 'powerdns', 'ddnss', 'linode', 'tencentcloud', 'dinahosting', 'hexonet', 'mailinabox', 'netcup', 'rfc2136'] %}
|
||||
tls {
|
||||
dns {{ dnsProvider }} {
|
||||
{% if dnsProvider == 'duckdns' %}
|
||||
@@ -452,6 +468,22 @@
|
||||
{% endif %}
|
||||
{% if dnsOptionalField1 %}password {{ dnsOptionalField1 }}
|
||||
{% endif %}
|
||||
{% elif dnsProvider == 'netcup' %}
|
||||
{% if dnsApiKey %}customer_number {{ dnsApiKey }}
|
||||
{% endif %}
|
||||
{% if dnsSecretApiKey %}api_key {{ dnsSecretApiKey }}
|
||||
{% endif %}
|
||||
{% if dnsOptionalField1 %}api_password {{ dnsOptionalField1 }}
|
||||
{% endif %}
|
||||
{% elif dnsProvider == 'rfc2136' %}
|
||||
{% if dnsApiKey %}key_name {{ dnsApiKey }}
|
||||
{% endif %}
|
||||
{% if dnsSecretApiKey %}key_alg {{ dnsSecretApiKey }}
|
||||
{% endif %}
|
||||
{% if dnsOptionalField1 %}key {{ dnsOptionalField1 }}
|
||||
{% endif %}
|
||||
{% if dnsOptionalField2 %}server {{ dnsOptionalField2 }}
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user