Documentation ¶
Index ¶
- type Domain
- type DomainRecord
- type LiveDNS
- func (g *LiveDNS) AddSlaveToDomain(fqdn, host string) (err error)
- func (g *LiveDNS) AddTsigToDomain(fqdn, uuid string) (err error)
- func (g *LiveDNS) AssociateTSIGKeyWithDomain(fqdn string, id string) (response types.StandardResponse, err error)
- func (g *LiveDNS) CreateDomain(fqdn string, ttl int) (response types.StandardResponse, err error)
- func (g *LiveDNS) CreateDomainRecord(fqdn, name, recordtype string, ttl int, values []string) (response types.StandardResponse, err error)
- func (g *LiveDNS) CreateSnapshot(fqdn string) (response types.StandardResponse, err error)
- func (g *LiveDNS) CreateTSIGKey(fqdn string) (response TSIGKey, err error)
- func (g *LiveDNS) CreateTsig() (tsig Tsig, err error)
- func (g *LiveDNS) DelSlaveFromDomain(fqdn, host string) (err error)
- func (g *LiveDNS) DeleteAllDomainRecords(fqdn string) (err error)
- func (g *LiveDNS) DeleteDomainKey(fqdn, uuid string) (err error)
- func (g *LiveDNS) DeleteDomainRecord(fqdn, name, recordtype string) (err error)
- func (g *LiveDNS) DeleteDomainRecordsByName(fqdn, name string) (err error)
- func (g *LiveDNS) DeleteSnapshot(fqdn, snapUUID string) (err error)
- func (g *LiveDNS) GetDomain(fqdn string) (domain Domain, err error)
- func (g *LiveDNS) GetDomainKey(fqdn, uuid string) (key SigningKey, err error)
- func (g *LiveDNS) GetDomainKeys(fqdn string) (keys []SigningKey, err error)
- func (g *LiveDNS) GetDomainNS(fqdn string) (ns []string, err error)
- func (g *LiveDNS) GetDomainRecordByNameAndType(fqdn, name, recordtype string) (record DomainRecord, err error)
- func (g *LiveDNS) GetDomainRecords(fqdn string) (records []DomainRecord, err error)
- func (g *LiveDNS) GetDomainRecordsAsText(uuid string) ([]byte, error)
- func (g *LiveDNS) GetDomainRecordsByName(fqdn, name string) (records []DomainRecord, err error)
- func (g *LiveDNS) GetDomainTSIGKeys(fqdn string) (response []TSIGKey, err error)
- func (g *LiveDNS) GetSnapshot(fqdn, snapUUID string) (snapshot Snapshot, err error)
- func (g *LiveDNS) GetTSIGKey(id string) (response TSIGKey, err error)
- func (g *LiveDNS) GetTSIGKeys() (response []TSIGKey, err error)
- func (g *LiveDNS) GetTsig(uuid string) (tsig Tsig, err error)
- func (g *LiveDNS) GetTsigBIND(uuid string) ([]byte, error)
- func (g *LiveDNS) GetTsigKnot(uuid string) ([]byte, error)
- func (g *LiveDNS) GetTsigNSD(uuid string) ([]byte, error)
- func (g *LiveDNS) GetTsigPowerDNS(uuid string) ([]byte, error)
- func (g *LiveDNS) ListDomains() (domains []Domain, err error)
- func (g *LiveDNS) ListSlavesInDomain(fqdn string) (slaves []string, err error)
- func (g *LiveDNS) ListSnapshots(fqdn string) (snapshots []Snapshot, err error)
- func (g *LiveDNS) ListTsigs() (tsigs []Tsig, err error)
- func (g *LiveDNS) RemoveTSIGKeyFromDomain(fqdn string, id string) (err error)
- func (g *LiveDNS) SignDomain(fqdn string) (response types.StandardResponse, err error)
- func (g *LiveDNS) UpdateDomain(fqdn string, details UpdateDomainRequest) (response types.StandardResponse, err error)
- func (g *LiveDNS) UpdateDomainKey(fqdn, uuid string, deleted bool) (err error)
- func (g *LiveDNS) UpdateDomainRecordByNameAndType(fqdn, name, recordtype string, ttl int, values []string) (response types.StandardResponse, err error)
- func (g *LiveDNS) UpdateDomainRecords(fqdn string, records []DomainRecord) (response types.StandardResponse, err error)
- func (g *LiveDNS) UpdateDomainRecordsByName(fqdn, name string, records []DomainRecord) (response types.StandardResponse, err error)
- type SigningKey
- type Snapshot
- type TSIGKey
- type Tsig
- type UpdateDomainRequest
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Domain ¶
type Domain struct { FQDN string `json:"fqdn,omitempty"` DomainHref string `json:"domain_href,omitempty"` DomainKeysHref string `json:"domain_keys_href,omitempty"` DomainRecordsHref string `json:"domain_records_href,omitempty"` AutomaticSnapshots *bool `json:"automatic_snapshots,omitempty"` }
Domain represents a DNS domain
type DomainRecord ¶
type DomainRecord struct { RrsetType string `json:"rrset_type,omitempty"` RrsetTTL int `json:"rrset_ttl,omitempty"` RrsetName string `json:"rrset_name,omitempty"` RrsetHref string `json:"rrset_href,omitempty"` RrsetValues []string `json:"rrset_values,omitempty"` }
DomainRecord represents a DNS Record
type LiveDNS ¶
type LiveDNS struct {
// contains filtered or unexported fields
}
LiveDNS is the API client to the Gandi v5 LiveDNS API
func NewFromClient ¶
NewFromClient returns an instance of the LiveDNS API client
func (*LiveDNS) AddSlaveToDomain ¶
AddSlaveToDomain adds a slave to a domain
func (*LiveDNS) AddTsigToDomain ¶
AddTsigToDomain adds a tsig to a domain
func (*LiveDNS) AssociateTSIGKeyWithDomain ¶
func (g *LiveDNS) AssociateTSIGKeyWithDomain(fqdn string, id string) (response types.StandardResponse, err error)
AssociateTSIGKeyWithDomain retrieves the specified TSIG key
func (*LiveDNS) CreateDomain ¶
CreateDomain adds a domain to a zone
func (*LiveDNS) CreateDomainRecord ¶
func (g *LiveDNS) CreateDomainRecord(fqdn, name, recordtype string, ttl int, values []string) (response types.StandardResponse, err error)
CreateDomainRecord creates a record in the zone attached to a domain
func (*LiveDNS) CreateSnapshot ¶
func (g *LiveDNS) CreateSnapshot(fqdn string) (response types.StandardResponse, err error)
CreateSnapshot creates a snapshot for a domain
func (*LiveDNS) CreateTSIGKey ¶
CreateTSIGKey creates a TSIG key
func (*LiveDNS) CreateTsig ¶
CreateTsig creates a tsig
func (*LiveDNS) DelSlaveFromDomain ¶
DelSlaveFromDomain removes a slave from a domain
func (*LiveDNS) DeleteAllDomainRecords ¶
DeleteAllDomainRecords deletes all records in the zone attached to a domain
func (*LiveDNS) DeleteDomainKey ¶
DeleteDomainKey deletes a signing key from a domain
func (*LiveDNS) DeleteDomainRecord ¶
DeleteDomainRecord deletes the record with the given name and the given type in the zone attached to a domain
func (*LiveDNS) DeleteDomainRecordsByName ¶
DeleteDomainRecordsByName deletes all records with the given name in the zone attached to a domain
func (*LiveDNS) DeleteSnapshot ¶
DeleteSnapshot deletes a snapshot for a domain
func (*LiveDNS) GetDomainKey ¶
func (g *LiveDNS) GetDomainKey(fqdn, uuid string) (key SigningKey, err error)
GetDomainKey return a specific signing key from a domain
func (*LiveDNS) GetDomainKeys ¶
func (g *LiveDNS) GetDomainKeys(fqdn string) (keys []SigningKey, err error)
GetDomainKeys returns data about the signing keys created for a domain
func (*LiveDNS) GetDomainNS ¶
GetDomainNS returns the list of the nameservers for a domain
func (*LiveDNS) GetDomainRecordByNameAndType ¶
func (g *LiveDNS) GetDomainRecordByNameAndType(fqdn, name, recordtype string) (record DomainRecord, err error)
GetDomainRecordByNameAndType gets the record with specific name and type in the zone attached to the domain
func (*LiveDNS) GetDomainRecords ¶
func (g *LiveDNS) GetDomainRecords(fqdn string) (records []DomainRecord, err error)
GetDomainRecords lists all records in the zone associated with a domain
func (*LiveDNS) GetDomainRecordsAsText ¶
GetDomainRecordsAsText lists all records in a zone and returns them as a text file ... and by text, I mean a slice of bytes
func (*LiveDNS) GetDomainRecordsByName ¶
func (g *LiveDNS) GetDomainRecordsByName(fqdn, name string) (records []DomainRecord, err error)
GetDomainRecordsByName lists all records with a specific name in a zone
func (*LiveDNS) GetDomainTSIGKeys ¶
GetDomainTSIGKeys retrieves the specified TSIG key
func (*LiveDNS) GetSnapshot ¶
GetSnapshot returns a snapshot for a domain
func (*LiveDNS) GetTSIGKey ¶
GetTSIGKey retrieves the specified TSIG key
func (*LiveDNS) GetTSIGKeys ¶
GetTSIGKeys retrieves all the TSIG keys for the account
func (*LiveDNS) GetTsigBIND ¶
GetTsigBIND shows a BIND nameserver config, and includes the nameservers available for zone transfers
func (*LiveDNS) GetTsigKnot ¶
GetTsigKnot shows a Knot nameserver config, and includes the nameservers available for zone transfers
func (*LiveDNS) GetTsigNSD ¶
GetTsigNSD shows a NSD nameserver config, and includes the nameservers available for zone transfers
func (*LiveDNS) GetTsigPowerDNS ¶
GetTsigPowerDNS shows a PowerDNS nameserver config, and includes the nameservers available for zone transfers
func (*LiveDNS) ListDomains ¶
ListDomains lists all domains
func (*LiveDNS) ListSlavesInDomain ¶
ListSlavesInDomain lists slaves in a domain
func (*LiveDNS) ListSnapshots ¶
ListSnapshots lists all snapshots for a domain
func (*LiveDNS) RemoveTSIGKeyFromDomain ¶
RemoveTSIGKeyFromDomain retrieves the specified TSIG key
func (*LiveDNS) SignDomain ¶
func (g *LiveDNS) SignDomain(fqdn string) (response types.StandardResponse, err error)
SignDomain creates a DNSKEY and asks Gandi servers to automatically sign the domain. The UUID of the created key is stored into the response.UUID field.
func (*LiveDNS) UpdateDomain ¶
func (g *LiveDNS) UpdateDomain(fqdn string, details UpdateDomainRequest) (response types.StandardResponse, err error)
UpdateDomain changes the zone associated to a domain
func (*LiveDNS) UpdateDomainKey ¶
UpdateDomainKey updates a signing key for a domain (only the deleted status, actually...)
func (*LiveDNS) UpdateDomainRecordByNameAndType ¶
func (g *LiveDNS) UpdateDomainRecordByNameAndType(fqdn, name, recordtype string, ttl int, values []string) (response types.StandardResponse, err error)
UpdateDomainRecordByNameAndType changes the record with the given name and the given type in the zone attached to a domain
func (*LiveDNS) UpdateDomainRecords ¶
func (g *LiveDNS) UpdateDomainRecords(fqdn string, records []DomainRecord) (response types.StandardResponse, err error)
UpdateDomainRecords changes all records in the zone attached to a domain
func (*LiveDNS) UpdateDomainRecordsByName ¶
func (g *LiveDNS) UpdateDomainRecordsByName(fqdn, name string, records []DomainRecord) (response types.StandardResponse, err error)
UpdateDomainRecordsByName changes all records with the given name in the zone attached to the domain
type SigningKey ¶
type SigningKey struct { Status string `json:"status,omitempty"` UUID string `json:"id,omitempty"` Algorithm int `json:"algorithm,omitempty"` Deleted *bool `json:"deleted,omitempty"` AlgorithmName string `json:"algorithm_name,omitempty"` FQDN string `json:"fqdn,omitempty"` Flags int `json:"flags,omitempty"` DS string `json:"ds,omitempty"` PublicKey string `json:"public_key,omitempty"` Tag int `json:"tag,omitempty"` KeyHref string `json:"key_href,omitempty"` }
SigningKey holds data about a DNSSEC signing key
type Snapshot ¶
type Snapshot struct { Automatic *bool `json:"automatic,omitempty"` CreatedAt time.Time `json:"created_at,omitempty"` ID string `json:"id,omitempty"` Name string `json:"name,omitempty"` SnapshotHREF string `json:"snapshot_href,omitempty"` ZoneData []DomainRecord `json:"zone_data,omitempty"` }
Snapshot represents a point in time record of a domain
type TSIGKey ¶
type TSIGKey struct { KeyHREF string `json:"href,omitempty"` ID string `json:"id,omitempty"` KeyName string `json:"key_name,omitempty"` Secret string `json:"secret,omitempty"` ConfigSamples configSamples `json:"config_samples,omitempty"` }
TSIGKey describes the TSIG key associated with an AXFR secondary
type Tsig ¶
type Tsig struct { KeyName string `json:"key_name,omitempty"` Secret string `json:"secret,omitempty"` UUID string `json:"uuid,omitempty"` AxfrTsigURL string `json:"axfr_tsig_url,omitempty"` ConfigSamples interface{} `json:"config_samples,omitempty"` }
Tsig contains tsig data (no kidding!)
type UpdateDomainRequest ¶
type UpdateDomainRequest struct {
AutomaticSnapshots *bool `json:"automatic_snapshots,omitempty"`
}
UpdateDomainRequest contains the params for the UpdateDomain method