Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CloudFlareProvider ¶
type CloudFlareProvider struct {
// contains filtered or unexported fields
}
CloudFlareProvider encapsulates a CloudFlare DDNS provider.
func (CloudFlareProvider) SetRecord ¶
func (cf CloudFlareProvider) SetRecord(fqdn string, record Record) error
SetRecord sets the `record` for fully qualified domain name `fqdn`
func (CloudFlareProvider) VerifyConfig ¶
func (cf CloudFlareProvider) VerifyConfig() error
VerifyConfig checks the provided credential can access zone information.
type Provider ¶
type Provider interface {
// Veirfy if the provided environment variables can be used to access DDNS service correctly.
// For example, check if the login credentials are correct (can successfully update DNS record).
VerifyConfig() error
// Set DNS zone record.
SetRecord(fqdn string, record Record) error
}
Provider interface is responsible for get and set DNS zone records to a DDNS service provider.
func CreateCloudFlareProvider ¶
CreateCloudFlareProvider creates a DDNS Provider for CloudFlare.
Click to show internal directories.
Click to hide internal directories.