Documentation ¶
Index ¶
- Constants
- Variables
- func DecryptText(text string, aesKey []byte) (decryptResult string, encryptNonce string, err error)
- func EncryptText(text string, aesKey []byte, nonceEncoded []byte) (string, error)
- func GenerateNonce() ([]byte, error)
- type DNSEndpoint
- type DNSEndpointList
- type DNSEndpointSpec
- type DNSEndpointStatus
- type DomainFilter
- type Endpoint
- func (in *Endpoint) DeepCopy() *Endpoint
- func (in *Endpoint) DeepCopyInto(out *Endpoint)
- func (e *Endpoint) DeleteProviderSpecificProperty(key string)
- func (e *Endpoint) GetProviderSpecificProperty(key string) (string, bool)
- func (e *Endpoint) IsOwnedBy(ownerID string) bool
- func (e *Endpoint) Key() EndpointKey
- func (e *Endpoint) SetProviderSpecificProperty(key string, value string)
- func (e *Endpoint) String() string
- func (e *Endpoint) WithProviderSpecific(key, value string) *Endpoint
- func (e *Endpoint) WithSetIdentifier(setIdentifier string) *Endpoint
- type EndpointKey
- type Labels
- type MatchAllDomainFilters
- type ProviderSpecific
- type ProviderSpecificProperty
- type TTL
- type TargetFilterInterface
- type TargetNetFilter
- type Targets
Constants ¶
const ( // RecordTypeA is a RecordType enum value RecordTypeA = "A" // RecordTypeAAAA is a RecordType enum value RecordTypeAAAA = "AAAA" // RecordTypeCNAME is a RecordType enum value RecordTypeCNAME = "CNAME" // RecordTypeTXT is a RecordType enum value RecordTypeTXT = "TXT" // RecordTypeSRV is a RecordType enum value RecordTypeSRV = "SRV" // RecordTypeNS is a RecordType enum value RecordTypeNS = "NS" // RecordTypePTR is a RecordType enum value RecordTypePTR = "PTR" // RecordTypeMX is a RecordType enum value RecordTypeMX = "MX" // RecordTypeNAPTR is a RecordType enum value RecordTypeNAPTR = "NAPTR" )
const ( // OwnerLabelKey is the name of the label that defines the owner of an Endpoint. OwnerLabelKey = "owner" // ResourceLabelKey is the name of the label that identifies k8s resource which wants to acquire the DNS name ResourceLabelKey = "resource" // OwnedRecordLabelKey is the name of the label that identifies the record that is owned by the labeled TXT registry record OwnedRecordLabelKey = "ownedRecord" // AWSSDDescriptionLabel label responsible for storing raw owner/resource combination information in the Labels // supposed to be inserted by AWS SD Provider, and parsed into OwnerLabelKey and ResourceLabelKey key by AWS SD Registry AWSSDDescriptionLabel = "aws-sd-description" // DualstackLabelKey is the name of the label that identifies dualstack endpoints DualstackLabelKey = "dualstack" )
Variables ¶
var ErrInvalidHeritage = errors.New("heritage is unknown or not found")
ErrInvalidHeritage is returned when heritage was not found, or different heritage is found
Functions ¶
func DecryptText ¶ added in v0.13.5
DecryptText decrypt gziped data using a supplied AES encryption key ang ungzip it in case of decryption failed, will return original input and decryption error
func EncryptText ¶ added in v0.13.5
EncryptText gzip input data and encrypts it using the supplied AES key
func GenerateNonce ¶ added in v0.14.0
GenerateNonce creates a random nonce of a fixed size
Types ¶
type DNSEndpoint ¶ added in v0.5.6
type DNSEndpoint struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` Spec DNSEndpointSpec `json:"spec,omitempty"` Status DNSEndpointStatus `json:"status,omitempty"` }
func (*DNSEndpoint) DeepCopy ¶ added in v0.5.6
func (in *DNSEndpoint) DeepCopy() *DNSEndpoint
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DNSEndpoint.
func (*DNSEndpoint) DeepCopyInto ¶ added in v0.5.6
func (in *DNSEndpoint) DeepCopyInto(out *DNSEndpoint)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*DNSEndpoint) DeepCopyObject ¶ added in v0.5.6
func (in *DNSEndpoint) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type DNSEndpointList ¶ added in v0.5.6
type DNSEndpointList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []DNSEndpoint `json:"items"` }
+kubebuilder:object:root=true DNSEndpointList is a list of DNSEndpoint objects
func (*DNSEndpointList) DeepCopy ¶ added in v0.5.6
func (in *DNSEndpointList) DeepCopy() *DNSEndpointList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DNSEndpointList.
func (*DNSEndpointList) DeepCopyInto ¶ added in v0.5.6
func (in *DNSEndpointList) DeepCopyInto(out *DNSEndpointList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*DNSEndpointList) DeepCopyObject ¶ added in v0.5.6
func (in *DNSEndpointList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type DNSEndpointSpec ¶ added in v0.5.6
type DNSEndpointSpec struct {
Endpoints []*Endpoint `json:"endpoints,omitempty"`
}
DNSEndpointSpec defines the desired state of DNSEndpoint
func (*DNSEndpointSpec) DeepCopy ¶ added in v0.5.6
func (in *DNSEndpointSpec) DeepCopy() *DNSEndpointSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DNSEndpointSpec.
func (*DNSEndpointSpec) DeepCopyInto ¶ added in v0.5.6
func (in *DNSEndpointSpec) DeepCopyInto(out *DNSEndpointSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type DNSEndpointStatus ¶ added in v0.5.6
type DNSEndpointStatus struct { // The generation observed by the external-dns controller. // +optional ObservedGeneration int64 `json:"observedGeneration,omitempty"` }
DNSEndpointStatus defines the observed state of DNSEndpoint
func (*DNSEndpointStatus) DeepCopy ¶ added in v0.5.6
func (in *DNSEndpointStatus) DeepCopy() *DNSEndpointStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DNSEndpointStatus.
func (*DNSEndpointStatus) DeepCopyInto ¶ added in v0.5.6
func (in *DNSEndpointStatus) DeepCopyInto(out *DNSEndpointStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type DomainFilter ¶ added in v0.7.0
type DomainFilter struct { // Filters define what domains to match Filters []string // contains filtered or unexported fields }
DomainFilter holds a lists of valid domain names
func NewDomainFilter ¶ added in v0.7.0
func NewDomainFilter(domainFilters []string) DomainFilter
NewDomainFilter returns a new DomainFilter given a comma separated list of domains
func NewDomainFilterWithExclusions ¶ added in v0.7.0
func NewDomainFilterWithExclusions(domainFilters []string, excludeDomains []string) DomainFilter
NewDomainFilterWithExclusions returns a new DomainFilter, given a list of matches and exclusions
func NewRegexDomainFilter ¶ added in v0.8.0
func NewRegexDomainFilter(regexDomainFilter *regexp.Regexp, regexDomainExclusion *regexp.Regexp) DomainFilter
NewRegexDomainFilter returns a new DomainFilter given a regular expression
func (DomainFilter) IsConfigured ¶ added in v0.7.0
func (df DomainFilter) IsConfigured() bool
IsConfigured returns true if any inclusion or exclusion rules have been specified.
func (DomainFilter) MarshalJSON ¶ added in v0.13.6
func (df DomainFilter) MarshalJSON() ([]byte, error)
func (DomainFilter) Match ¶ added in v0.7.0
func (df DomainFilter) Match(domain string) bool
Match checks whether a domain can be found in the DomainFilter. RegexFilter takes precedence over Filters
func (DomainFilter) MatchParent ¶ added in v0.9.0
func (df DomainFilter) MatchParent(domain string) bool
func (*DomainFilter) UnmarshalJSON ¶ added in v0.13.6
func (df *DomainFilter) UnmarshalJSON(b []byte) error
type Endpoint ¶
type Endpoint struct { // The hostname of the DNS record DNSName string `json:"dnsName,omitempty"` // The targets the DNS record points to Targets Targets `json:"targets,omitempty"` // RecordType type of record, e.g. CNAME, A, AAAA, SRV, TXT etc RecordType string `json:"recordType,omitempty"` // Identifier to distinguish multiple records with the same name and type (e.g. Route53 records with routing policies other than 'simple') SetIdentifier string `json:"setIdentifier,omitempty"` // TTL for the record RecordTTL TTL `json:"recordTTL,omitempty"` // Labels stores labels defined for the Endpoint // +optional Labels Labels `json:"labels,omitempty"` // ProviderSpecific stores provider specific config // +optional ProviderSpecific ProviderSpecific `json:"providerSpecific,omitempty"` }
Endpoint is a high-level way of a connection between a service and an IP
func FilterEndpointsByOwnerID ¶ added in v0.14.0
Apply filter to slice of endpoints and return new filtered slice that includes only endpoints that match.
func NewEndpoint ¶ added in v0.2.0
NewEndpoint initialization method to be used to create an endpoint
func NewEndpointWithTTL ¶ added in v0.4.6
NewEndpointWithTTL initialization method to be used to create an endpoint with a TTL struct
func (*Endpoint) DeepCopy ¶ added in v0.5.6
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Endpoint.
func (*Endpoint) DeepCopyInto ¶ added in v0.5.6
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*Endpoint) DeleteProviderSpecificProperty ¶ added in v0.13.6
DeleteProviderSpecificProperty deletes any ProviderSpecificProperty of the specified name.
func (*Endpoint) GetProviderSpecificProperty ¶ added in v0.5.10
GetProviderSpecificProperty returns the value of a ProviderSpecificProperty if the property exists.
func (*Endpoint) IsOwnedBy ¶ added in v0.14.0
IsOwnedBy returns true if the endpoint owner label matches the given ownerID, false otherwise
func (*Endpoint) Key ¶ added in v0.13.6
func (e *Endpoint) Key() EndpointKey
Key returns the EndpointKey of the Endpoint.
func (*Endpoint) SetProviderSpecificProperty ¶ added in v0.13.6
SetProviderSpecificProperty sets the value of a ProviderSpecificProperty.
func (*Endpoint) WithProviderSpecific ¶ added in v0.5.8
WithProviderSpecific attaches a key/value pair to the Endpoint and returns the Endpoint. This can be used to pass additional data through the stages of ExternalDNS's Endpoint processing. The assumption is that most of the time this will be provider specific metadata that doesn't warrant its own field on the Endpoint object itself. It differs from Labels in the fact that it's not persisted in the Registry but only kept in memory during a single record synchronization.
func (*Endpoint) WithSetIdentifier ¶ added in v0.5.18
WithSetIdentifier applies the given set identifier to the endpoint.
type EndpointKey ¶ added in v0.13.6
EndpointKey is the type of a map key for separating endpoints or targets.
type Labels ¶ added in v0.5.0
Labels store metadata related to the endpoint it is then stored in a persistent storage via serialization
func NewLabelsFromString ¶ added in v0.5.0
func NewLabelsFromStringPlain ¶ added in v0.13.5
NewLabelsFromString constructs endpoints labels from a provided format string if heritage set to another value is found then error is returned no heritage automatically assumes is not owned by external-dns and returns invalidHeritage error
func (Labels) DeepCopy ¶ added in v0.5.6
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Labels.
func (Labels) DeepCopyInto ¶ added in v0.5.6
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (Labels) Serialize ¶ added in v0.5.0
Serialize same to SerializePlain, but encrypt data, if encryption enabled
func (Labels) SerializePlain ¶ added in v0.13.5
SerializePlain transforms endpoints labels into a external-dns recognizable format string withQuotes adds additional quotes
type MatchAllDomainFilters ¶ added in v0.9.0
type MatchAllDomainFilters []*DomainFilter
func (MatchAllDomainFilters) Match ¶ added in v0.9.0
func (f MatchAllDomainFilters) Match(domain string) bool
type ProviderSpecific ¶ added in v0.5.6
type ProviderSpecific []ProviderSpecificProperty
ProviderSpecific holds configuration which is specific to individual DNS providers
func (ProviderSpecific) DeepCopy ¶ added in v0.5.6
func (in ProviderSpecific) DeepCopy() ProviderSpecific
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ProviderSpecific.
func (ProviderSpecific) DeepCopyInto ¶ added in v0.5.6
func (in ProviderSpecific) DeepCopyInto(out *ProviderSpecific)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ProviderSpecificProperty ¶ added in v0.5.10
type ProviderSpecificProperty struct { Name string `json:"name,omitempty"` Value string `json:"value,omitempty"` }
ProviderSpecificProperty holds the name and value of a configuration which is specific to individual DNS providers
type TTL ¶ added in v0.4.6
type TTL int64
TTL is a structure defining the TTL of a DNS record
func (TTL) IsConfigured ¶ added in v0.4.6
IsConfigured returns true if TTL is configured, false otherwise
type TargetFilterInterface ¶ added in v0.13.0
TargetFilterInterface defines the interface to select matching targets for a specific provider or runtime
type TargetNetFilter ¶ added in v0.13.0
type TargetNetFilter struct { // FilterNets define what targets to match FilterNets []*net.IPNet // contains filtered or unexported fields }
TargetNetFilter holds a lists of valid target names
func NewTargetNetFilterWithExclusions ¶ added in v0.13.0
func NewTargetNetFilterWithExclusions(targetFilterNets []string, excludeNets []string) TargetNetFilter
NewTargetNetFilterWithExclusions returns a new TargetNetFilter, given a list of matches and exclusions
func (TargetNetFilter) Match ¶ added in v0.13.0
func (tf TargetNetFilter) Match(target string) bool
Match checks whether a target can be found in the TargetNetFilter.
type Targets ¶ added in v0.5.0
type Targets []string
Targets is a representation of a list of targets for an endpoint.
func NewTargets ¶ added in v0.5.0
NewTargets is a convenience method to create a new Targets object from a vararg of strings
func (Targets) DeepCopy ¶ added in v0.5.6
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Targets.
func (Targets) DeepCopyInto ¶ added in v0.5.6
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (Targets) IsLess ¶ added in v0.5.0
IsLess should fulfill the requirement to compare two targets and choose the 'lesser' one. In the past target was a simple string so simple string comparison could be used. Now we define 'less' as either being the shorter list of targets or where the first entry is less. FIXME We really need to define under which circumstances a list Targets is considered 'less' than another.