code: func validateClusterInfo(clusterName string, clusterInfo clientcmdapi.Cluster) []error {
  	validationErrors := make([]error, 0)
  
  	emptyCluster := clientcmdapi.NewCluster()
  	if reflect.DeepEqual(*emptyCluster, clusterInfo) {
  		return []error{ErrEmptyCluster}
  	}
  
  	if len(clusterInfo.Server) == 0 {
  		if len(clusterName) == 0 {
  			validationErrors = append(validationErrors, fmt.Errorf("default cluster has no server defined"))
  		} else {
  			validationErrors = append(validationErrors, fmt.Errorf("no server found for cluster %q", clusterName))
  		}
  	}
  	// Make sure CA data and CA file aren't both specified
  	if len(clusterInfo.CertificateAuthority) != 0 && len(clusterInfo.CertificateAuthorityData) != 0 {
  		validationErrors = append(validationErrors, fmt.Errorf("certificate-authority-data and certificate-authority are both specified for %v. certificate-authority-data will override.", clusterName))
  	}
  	if len(clusterInfo.CertificateAuthority) != 0 {
  		clientCertCA, err := os.Open(clusterInfo.CertificateAuthority)
  		defer clientCertCA.Close()
  		if err != nil {
  			validationErrors = append(validationErrors, fmt.Errorf("unable to read certificate-authority %v for %v due to %v", clusterInfo.CertificateAuthority, clusterName, err))
  		}
  	}
  
  	return validationErrors
  }
docs: // validateClusterInfo looks for conflicts and errors in the cluster info