mirror of
https://github.com/kubernetes-sigs/external-dns.git
synced 2025-10-13 10:51:01 +02:00
Fixed some formating mistakes
Signed-off-by: João Marçal <joao.marcal12@gmail.com>
This commit is contained in:
parent
9f6ebfa06d
commit
cb3f8c9ca5
@ -126,18 +126,18 @@ func (cs *crdSource) Endpoints() ([]*endpoint.Endpoint, error) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
illegalTarget := false
|
illegalTarget := false
|
||||||
for _, target := range ep.Targets{
|
for _, target := range ep.Targets {
|
||||||
if strings.HasSuffix(target, "."){
|
if strings.HasSuffix(target, ".") {
|
||||||
illegalTarget = true
|
illegalTarget = true
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if illegalTarget{
|
if illegalTarget {
|
||||||
log.Warnf("Endpoint %s with DNSName %s has Target illegal target. The subdomain must consist of lower case alphanumeric characters, '-' or '.', and must start and end with an alphanumeric character (e.g. 'example.com')", dnsEndpoint.ObjectMeta.Name, ep.DNSName)
|
log.Warnf("Endpoint %s with DNSName %s has Target illegal target. The subdomain must consist of lower case alphanumeric characters, '-' or '.', and must start and end with an alphanumeric character (e.g. 'example.com')", dnsEndpoint.ObjectMeta.Name, ep.DNSName)
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
|
|
||||||
if ep.Labels == nil{
|
if ep.Labels == nil {
|
||||||
ep.Labels = endpoint.NewLabels()
|
ep.Labels = endpoint.NewLabels()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user