diff --git a/backend/utils/ssl/client.go b/backend/utils/ssl/client.go index 8ca976960..8365f7c9b 100644 --- a/backend/utils/ssl/client.go +++ b/backend/utils/ssl/client.go @@ -15,6 +15,7 @@ import ( "github.com/go-acme/lego/v4/challenge/dns01" "github.com/go-acme/lego/v4/lego" "github.com/go-acme/lego/v4/providers/dns/alidns" + "github.com/go-acme/lego/v4/providers/dns/clouddns" "github.com/go-acme/lego/v4/providers/dns/cloudflare" "github.com/go-acme/lego/v4/providers/dns/dnspod" "github.com/go-acme/lego/v4/providers/dns/godaddy" @@ -70,6 +71,7 @@ const ( AliYun DnsType = "AliYun" Volcengine DnsType = "Volcengine" CloudFlare DnsType = "CloudFlare" + CloudDns DnsType = "CloudDns" NameSilo DnsType = "NameSilo" NameCheap DnsType = "NameCheap" NameCom DnsType = "NameCom" @@ -89,6 +91,8 @@ type DNSParam struct { APISecret string `json:"apiSecret"` SecretID string `json:"secretID"` Region string `json:"region"` + ClientID string `json:"clientID"` + Password string `json:"password"` } var ( @@ -140,6 +144,15 @@ func (c *AcmeClient) UseDns(dnsType DnsType, params string, websiteSSL model.Web cloudflareConfig.PollingInterval = pollingInterval cloudflareConfig.TTL = 3600 p, err = cloudflare.NewDNSProviderConfig(cloudflareConfig) + case CloudDns: + clouddnsConfig := clouddns.NewDefaultConfig() + clouddnsConfig.ClientID = param.ClientID + clouddnsConfig.Email = param.Email + clouddnsConfig.Password = param.Password + clouddnsConfig.PropagationTimeout = propagationTimeout + clouddnsConfig.PollingInterval = pollingInterval + clouddnsConfig.TTL = ttl + p, err = clouddns.NewDNSProviderConfig(clouddnsConfig) case NameCheap: namecheapConfig := namecheap.NewDefaultConfig() namecheapConfig.APIKey = param.APIkey diff --git a/frontend/src/global/mimetype.ts b/frontend/src/global/mimetype.ts index ce2d8bfc9..a4f0123fe 100644 --- a/frontend/src/global/mimetype.ts +++ b/frontend/src/global/mimetype.ts @@ -180,6 +180,10 @@ export const DNSTypes = [ label: 'Cloudflare', value: 'CloudFlare', }, + { + label: 'CloudDns', + value: 'CloudDns', + }, { label: 'NameSilo', value: 'NameSilo', diff --git a/frontend/src/views/website/ssl/dns-account/create/index.vue b/frontend/src/views/website/ssl/dns-account/create/index.vue index 61a8a10e6..59187cce1 100644 --- a/frontend/src/views/website/ssl/dns-account/create/index.vue +++ b/frontend/src/views/website/ssl/dns-account/create/index.vue @@ -77,6 +77,17 @@ +
+ + + + + + + + + +
({ apiUser: [Rules.requiredInput], secretID: [Rules.requiredInput], region: [Rules.requiredInput], + clientID: [Rules.requiredInput], + email: [Rules.email], + password: [Rules.requiredInput], }, }); const account = ref({