$ k get pod cluster1-mysql-0 -o yaml | grep subdomain
subdomain: cluster1-mysqlKubernetes has a check to match subdomain to service name:
func ShouldSetHostname(pod *v1.Pod, svc *v1.Service) bool {
return len(pod.Spec.Hostname) > 0 && pod.Spec.Subdomain == svc.Name && svc.Namespace == pod.Namespace
}That's why resolving cluster1-mysql-0.cluster1-mysql.default.svc.cluster.local works but cluster1-mysql-0.cluster1-mysql-unready.default.svc.cluster.local not.