traefik/vendor/github.com/xenolf/lego/providers/dns/dns_providers.go

114 lines
3.7 KiB
Go
Raw Normal View History

2017-02-07 21:33:23 +00:00
package dns
import (
"fmt"
2018-05-31 07:30:04 +00:00
"github.com/xenolf/lego/acme"
2017-02-07 21:33:23 +00:00
"github.com/xenolf/lego/providers/dns/auroradns"
"github.com/xenolf/lego/providers/dns/azure"
"github.com/xenolf/lego/providers/dns/bluecat"
2017-02-07 21:33:23 +00:00
"github.com/xenolf/lego/providers/dns/cloudflare"
"github.com/xenolf/lego/providers/dns/cloudxns"
2017-02-07 21:33:23 +00:00
"github.com/xenolf/lego/providers/dns/digitalocean"
"github.com/xenolf/lego/providers/dns/dnsimple"
"github.com/xenolf/lego/providers/dns/dnsmadeeasy"
"github.com/xenolf/lego/providers/dns/dnspod"
"github.com/xenolf/lego/providers/dns/duckdns"
2017-02-07 21:33:23 +00:00
"github.com/xenolf/lego/providers/dns/dyn"
"github.com/xenolf/lego/providers/dns/exec"
2017-02-07 21:33:23 +00:00
"github.com/xenolf/lego/providers/dns/exoscale"
"github.com/xenolf/lego/providers/dns/fastdns"
2017-02-07 21:33:23 +00:00
"github.com/xenolf/lego/providers/dns/gandi"
"github.com/xenolf/lego/providers/dns/gandiv5"
2018-05-31 07:30:04 +00:00
"github.com/xenolf/lego/providers/dns/gcloud"
"github.com/xenolf/lego/providers/dns/glesys"
"github.com/xenolf/lego/providers/dns/godaddy"
"github.com/xenolf/lego/providers/dns/lightsail"
2017-02-07 21:33:23 +00:00
"github.com/xenolf/lego/providers/dns/linode"
"github.com/xenolf/lego/providers/dns/namecheap"
"github.com/xenolf/lego/providers/dns/namedotcom"
2017-02-07 21:33:23 +00:00
"github.com/xenolf/lego/providers/dns/ns1"
2017-10-31 09:42:03 +00:00
"github.com/xenolf/lego/providers/dns/otc"
2017-02-07 21:33:23 +00:00
"github.com/xenolf/lego/providers/dns/ovh"
"github.com/xenolf/lego/providers/dns/pdns"
"github.com/xenolf/lego/providers/dns/rackspace"
"github.com/xenolf/lego/providers/dns/rfc2136"
"github.com/xenolf/lego/providers/dns/route53"
"github.com/xenolf/lego/providers/dns/vultr"
)
2018-05-31 07:30:04 +00:00
// NewDNSChallengeProviderByName Factory for DNS providers
func NewDNSChallengeProviderByName(name string) (acme.ChallengeProvider, error) {
2017-02-07 21:33:23 +00:00
var err error
2018-05-31 07:30:04 +00:00
var provider acme.ChallengeProvider
2017-02-07 21:33:23 +00:00
switch name {
case "azure":
provider, err = azure.NewDNSProvider()
case "auroradns":
provider, err = auroradns.NewDNSProvider()
case "bluecat":
provider, err = bluecat.NewDNSProvider()
2017-02-07 21:33:23 +00:00
case "cloudflare":
provider, err = cloudflare.NewDNSProvider()
case "cloudxns":
provider, err = cloudxns.NewDNSProvider()
2017-02-07 21:33:23 +00:00
case "digitalocean":
provider, err = digitalocean.NewDNSProvider()
case "dnsimple":
provider, err = dnsimple.NewDNSProvider()
case "dnsmadeeasy":
provider, err = dnsmadeeasy.NewDNSProvider()
case "dnspod":
provider, err = dnspod.NewDNSProvider()
case "duckdns":
provider, err = duckdns.NewDNSProvider()
2017-02-07 21:33:23 +00:00
case "dyn":
provider, err = dyn.NewDNSProvider()
case "fastdns":
provider, err = fastdns.NewDNSProvider()
2017-02-07 21:33:23 +00:00
case "exoscale":
2017-10-31 09:42:03 +00:00
provider, err = exoscale.NewDNSProvider()
2017-02-07 21:33:23 +00:00
case "gandi":
provider, err = gandi.NewDNSProvider()
case "gandiv5":
provider, err = gandiv5.NewDNSProvider()
case "glesys":
provider, err = glesys.NewDNSProvider()
2017-02-07 21:33:23 +00:00
case "gcloud":
2018-05-31 07:30:04 +00:00
provider, err = gcloud.NewDNSProvider()
case "godaddy":
provider, err = godaddy.NewDNSProvider()
case "lightsail":
provider, err = lightsail.NewDNSProvider()
2017-02-07 21:33:23 +00:00
case "linode":
provider, err = linode.NewDNSProvider()
case "manual":
2018-05-31 07:30:04 +00:00
provider, err = acme.NewDNSProviderManual()
2017-02-07 21:33:23 +00:00
case "namecheap":
provider, err = namecheap.NewDNSProvider()
case "namedotcom":
provider, err = namedotcom.NewDNSProvider()
2017-02-07 21:33:23 +00:00
case "rackspace":
provider, err = rackspace.NewDNSProvider()
case "route53":
provider, err = route53.NewDNSProvider()
case "rfc2136":
provider, err = rfc2136.NewDNSProvider()
case "vultr":
provider, err = vultr.NewDNSProvider()
case "ovh":
provider, err = ovh.NewDNSProvider()
case "pdns":
provider, err = pdns.NewDNSProvider()
case "ns1":
provider, err = ns1.NewDNSProvider()
2017-10-31 09:42:03 +00:00
case "otc":
provider, err = otc.NewDNSProvider()
case "exec":
provider, err = exec.NewDNSProvider()
2017-02-07 21:33:23 +00:00
default:
2018-05-31 07:30:04 +00:00
err = fmt.Errorf("unrecognised DNS provider: %s", name)
2017-02-07 21:33:23 +00:00
}
return provider, err
}