Documentation ¶
Overview ¶
Package selectelv2 implements a DNS provider for solving the DNS-01 challenge using Selectel Domains APIv2.
Index ¶
Constants ¶
const ( EnvBaseURL = envNamespace + "BASE_URL" EnvUsernameOS = envNamespace + "USERNAME" EnvPasswordOS = envNamespace + "PASSWORD" EnvAccount = envNamespace + "ACCOUNT_ID" EnvProjectID = envNamespace + "PROJECT_ID" EnvTTL = envNamespace + "TTL" EnvPropagationTimeout = envNamespace + "PROPAGATION_TIMEOUT" EnvPollingInterval = envNamespace + "POLLING_INTERVAL" EnvHTTPTimeout = envNamespace + "HTTP_TIMEOUT" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { BaseURL string Username string Password string Account string ProjectID string TTL int PropagationTimeout time.Duration PollingInterval time.Duration HTTPClient *http.Client }
Config is used to configure the creation of the DNSProvider.
func NewDefaultConfig ¶
func NewDefaultConfig() *Config
NewDefaultConfig returns a default configuration for the DNSProvider.
type DNSProvider ¶
type DNSProvider struct {
// contains filtered or unexported fields
}
func NewDNSProvider ¶
func NewDNSProvider() (*DNSProvider, error)
NewDNSProvider returns a DNSProvider instance configured for Selectel Domains APIv2.
func NewDNSProviderConfig ¶
func NewDNSProviderConfig(config *Config) (*DNSProvider, error)
NewDNSProviderConfig return a DNSProvider instance configured for selectel.
func (*DNSProvider) CleanUp ¶
func (p *DNSProvider) CleanUp(domain, _, keyAuth string) error
CleanUp removes a TXT record used for DNS-01 challenge.
func (*DNSProvider) Present ¶
func (p *DNSProvider) Present(domain, _, keyAuth string) error
Present creates a TXT record to fulfill DNS-01 challenge.
func (*DNSProvider) Timeout ¶
func (p *DNSProvider) Timeout() (timeout, interval time.Duration)
Timeout returns the Timeout and interval to use when checking for DNS propagation. Adjusting here to cope with spikes in propagation times.