Skip to content

Commit 067b3c2

Browse files
authored
Fix controlplane version type
Fix controlplane version type
2 parents b3d8e57 + 1085df2 commit 067b3c2

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

pkg/controller/ops/gcp.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,14 +40,14 @@ func (r *ClusterOpsRequestReconciler) updateGCPManagedControlPlane(namespacedNam
4040
}
4141
_, err = clientutil.CreateOrPatch(r.ctx, r.KBClient, gcpManagedCP, func(obj client.Object, createOp bool) client.Object {
4242
in := obj.(*capg.GCPManagedControlPlane)
43-
in.Spec.ControlPlaneVersion = clusterOps.Spec.UpdateVersion.TargetVersion.Cluster
43+
in.Spec.Version = clusterOps.Spec.UpdateVersion.TargetVersion.Cluster
4444
return in
4545
})
4646
if err != nil {
4747
return false, err
4848
}
4949

50-
if !r.isGCPManagedControlPlaneReady(gcpManagedCP) || !isVersionEqual(gcpManagedCP.Status.CurrentVersion, ptr.Deref(clusterOps.Spec.UpdateVersion.TargetVersion.Cluster, "")) {
50+
if !r.isGCPManagedControlPlaneReady(gcpManagedCP) || !isVersionEqual(*gcpManagedCP.Status.Version, ptr.Deref(clusterOps.Spec.UpdateVersion.TargetVersion.Cluster, "")) {
5151
r.Log.Info("Waiting for GCPManagedControlPlane to be ready")
5252
return true, nil
5353
}

0 commit comments

Comments
 (0)