dns_acmedns

This commit is contained in:
Jamie Curnow 2022-06-01 13:11:21 +04:00
parent 322048d5af
commit 523449f050
3 changed files with 73 additions and 0 deletions

View File

@ -36,6 +36,7 @@ func (p *Provider) GetAcmeEnvVars(meta interface{}) map[string]string {
// List returns an array of providers
func List() []Provider {
return []Provider{
getDNSAcmeDNS(),
getDNSAd(),
getDNSAli(),
getDNSAws(),

View File

@ -0,0 +1,69 @@
package dnsproviders
const acmeDNSchema = `
{
"type": "object",
"required": [
"api_url",
"user",
"password"
],
"additionalProperties": false,
"properties": {
"api_url": {
"type": "string",
"minLength": 4
},
"subdomain": {
"type": "string",
"minLength": 1
},
"user": {
"type": "string",
"minLength": 1
},
"password": {
"type": "string",
"minLength": 1
}
}
}
`
func getDNSAcmeDNS() Provider {
return Provider{
AcmeshName: "dns_acmedns",
Schema: acmeDNSchema,
Fields: []providerField{
{
Name: "Base URL",
Type: "text",
MetaKey: "api_url",
EnvKey: "ACMEDNS_BASE_URL",
IsRequired: true,
},
{
Name: "Subdomain",
Type: "text",
MetaKey: "subdomain",
EnvKey: "ACMEDNS_SUBDOMAIN",
IsRequired: true,
},
{
Name: "User",
Type: "text",
MetaKey: "user",
EnvKey: "ACMEDNS_USERNAME",
IsRequired: true,
},
{
Name: "Password",
Type: "password",
MetaKey: "password",
EnvKey: "ACMEDNS_PASSWORD",
IsRequired: true,
IsSecret: true,
},
},
}
}

View File

@ -2,6 +2,9 @@
"access-lists.title": {
"defaultMessage": "Access Lists"
},
"acmesh.dns_acmedns": {
"defaultMessage": "ACME DNS"
},
"acmesh.dns_ad": {
"defaultMessage": "Alwaysdata"
},