Skip to content

Commit

Permalink
Revert "handle the nil pointer exception in writeKubeconfig when no c…
Browse files Browse the repository at this point in the history
…luster resrouces"

This reverts commit 7942571.
  • Loading branch information
wwvela committed Dec 23, 2024
1 parent 7942571 commit 564ee3c
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions kubetest2/internal/deployers/eksapi/kubeconfig.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import (
"bytes"
"os"
"text/template"
"fmt"

"k8s.io/klog"
)
Expand Down Expand Up @@ -47,9 +46,6 @@ type kubeconfigTemplateParameters struct {
}

func writeKubeconfig(cluster *Cluster, kubeconfigPath string) error {
if cluster == nil {
return fmt.Errorf("Cluster is nil, you might need set --static-cluster-name or set --up to initial cluster resrouces")
}
klog.Infof("writing kubeconfig to %s for cluster: %s", kubeconfigPath, cluster.arn)
templateParams := kubeconfigTemplateParameters{
ClusterCertificateAuthority: cluster.certificateAuthorityData,
Expand Down

0 comments on commit 564ee3c

Please sign in to comment.