diff --git a/pkg/operator/ceph/cluster/rbd/controller.go b/pkg/operator/ceph/cluster/rbd/controller.go index 596dc6426..79e13d914 100644 --- a/pkg/operator/ceph/cluster/rbd/controller.go +++ b/pkg/operator/ceph/cluster/rbd/controller.go @@ -214,7 +214,8 @@ func (r *ReconcileCephRBDMirror) reconcile(request reconcile.Request) (reconcile // If the version of the Ceph monitor differs from the CephCluster CR image version we assume // the cluster is being upgraded. So the controller will just wait for the upgrade to finish and // then versions should match. Obviously using the cmd reporter job adds up to the deployment time - if !reflect.DeepEqual(*runningCephVersion, *desiredCephVersion) { + // Skip waiting for upgrades to finish in case of external cluster. + if !cephCluster.Spec.External.Enable && !reflect.DeepEqual(*runningCephVersion, *desiredCephVersion) { // Upgrade is in progress, let's wait for the mons to be done return opcontroller.WaitForRequeueIfCephClusterIsUpgrading, *cephRBDMirror, opcontroller.ErrorCephUpgradingRequeue(desiredCephVersion, runningCephVersion) diff --git a/pkg/operator/ceph/file/controller.go b/pkg/operator/ceph/file/controller.go index e362ff68c..8e970b387 100644 --- a/pkg/operator/ceph/file/controller.go +++ b/pkg/operator/ceph/file/controller.go @@ -306,7 +306,8 @@ func (r *ReconcileCephFilesystem) reconcile(request reconcile.Request) (reconcil // If the version of the Ceph monitor differs from the CephCluster CR image version we assume // the cluster is being upgraded. So the controller will just wait for the upgrade to finish and // then versions should match. Obviously using the cmd reporter job adds up to the deployment time - if !reflect.DeepEqual(*runningCephVersion, *desiredCephVersion) { + // Skip waiting for upgrades to finish in case of external cluster. + if !cephCluster.Spec.External.Enable && !reflect.DeepEqual(*runningCephVersion, *desiredCephVersion) { // Upgrade is in progress, let's wait for the mons to be done return opcontroller.WaitForRequeueIfCephClusterIsUpgrading, *cephFilesystem, opcontroller.ErrorCephUpgradingRequeue(desiredCephVersion, runningCephVersion) diff --git a/pkg/operator/ceph/file/mirror/controller.go b/pkg/operator/ceph/file/mirror/controller.go index 5fed3aaa5..cb9a2ee6e 100644 --- a/pkg/operator/ceph/file/mirror/controller.go +++ b/pkg/operator/ceph/file/mirror/controller.go @@ -204,7 +204,8 @@ func (r *ReconcileFilesystemMirror) reconcile(request reconcile.Request) (reconc // If the version of the Ceph monitor differs from the CephCluster CR image version we assume // the cluster is being upgraded. So the controller will just wait for the upgrade to finish and // then versions should match. Obviously using the cmd reporter job adds up to the deployment time - if !reflect.DeepEqual(*runningCephVersion, *desiredCephVersion) { + // Skip waiting for upgrades to finish in case of external cluster. + if !cephCluster.Spec.External.Enable && !reflect.DeepEqual(*runningCephVersion, *desiredCephVersion) { // Upgrade is in progress, let's wait for the mons to be done return opcontroller.WaitForRequeueIfCephClusterIsUpgrading, *filesystemMirror, opcontroller.ErrorCephUpgradingRequeue(desiredCephVersion, runningCephVersion) diff --git a/pkg/operator/ceph/nfs/controller.go b/pkg/operator/ceph/nfs/controller.go index f1a73f64a..950219f75 100644 --- a/pkg/operator/ceph/nfs/controller.go +++ b/pkg/operator/ceph/nfs/controller.go @@ -251,7 +251,8 @@ func (r *ReconcileCephNFS) reconcile(request reconcile.Request) (reconcile.Resul // If the version of the Ceph monitor differs from the CephCluster CR image version we assume // the cluster is being upgraded. So the controller will just wait for the upgrade to finish and // then versions should match. Obviously using the cmd reporter job adds up to the deployment time - if !reflect.DeepEqual(*runningCephVersion, *desiredCephVersion) { + // Skip waiting for upgrades to finish in case of external cluster. + if !cephCluster.Spec.External.Enable && !reflect.DeepEqual(*runningCephVersion, *desiredCephVersion) { // Upgrade is in progress, let's wait for the mons to be done return opcontroller.WaitForRequeueIfCephClusterIsUpgrading, *cephNFS, opcontroller.ErrorCephUpgradingRequeue(desiredCephVersion, runningCephVersion) diff --git a/pkg/operator/ceph/object/controller.go b/pkg/operator/ceph/object/controller.go index 9de9bef39..1b4e85ba3 100644 --- a/pkg/operator/ceph/object/controller.go +++ b/pkg/operator/ceph/object/controller.go @@ -324,7 +324,8 @@ func (r *ReconcileCephObjectStore) reconcile(request reconcile.Request) (reconci // If the version of the Ceph monitor differs from the CephCluster CR image version we assume // the cluster is being upgraded. So the controller will just wait for the upgrade to finish and // then versions should match. Obviously using the cmd reporter job adds up to the deployment time - if !reflect.DeepEqual(*runningCephVersion, *desiredCephVersion) { + // Skip waiting for upgrades to finish in case of external cluster. + if !cephCluster.Spec.External.Enable && !reflect.DeepEqual(*runningCephVersion, *desiredCephVersion) { // Upgrade is in progress, let's wait for the mons to be done return opcontroller.WaitForRequeueIfCephClusterIsUpgrading, *cephObjectStore,