Skip to content

Commit

Permalink
check value of cluster.Spec.Expose.Ingress
Browse files Browse the repository at this point in the history
  • Loading branch information
jp-gouin committed Jan 28, 2025
1 parent ebdeb3a commit 2019dec
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/controller/kubeconfig/kubeconfig.go
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ func getURLFromService(ctx context.Context, client client.Client, cluster *v1alp
nodePort := k3kService.Spec.Ports[0].NodePort
url = fmt.Sprintf("https://%s:%d", hostServerIP, nodePort)
}
if cluster.Spec.Expose.Ingress.Enabled {
if cluster.Spec.Expose.Ingress != nil && cluster.Spec.Expose.Ingress.Enabled {
var k3kIngress networkingv1.Ingress
ingressKey := types.NamespacedName{
Name: server.IngressName(cluster.Name),
Expand Down

0 comments on commit 2019dec

Please sign in to comment.