From 929d6ad8ca7f319a4ebcefde0202ca5f993d626b Mon Sep 17 00:00:00 2001 From: Sage Weil Date: Tue, 18 May 2021 09:54:15 -0500 Subject: [PATCH] qa/tasks/rook: simplify shutdown For some reason deleting common.yaml sometimes fails. Not really sure why, but since we will tear down kubernetes anyway this cleanup isn't really needed. Signed-off-by: Sage Weil --- qa/tasks/rook.py | 21 ++++++++++++--------- 1 file changed, 12 insertions(+), 9 deletions(-) diff --git a/qa/tasks/rook.py b/qa/tasks/rook.py index 140794a4bae..29cb6ef1e0d 100644 --- a/qa/tasks/rook.py +++ b/qa/tasks/rook.py @@ -147,19 +147,22 @@ def rook_operator(ctx, config): raise finally: - log.info('Cleaning up rook') + log.info('Cleaning up rook operator') _kubectl(ctx, config, [ 'delete', '-f', 'operator.yaml', ]) - _kubectl(ctx, config, [ - 'delete', - '-f', 'rook/cluster/examples/kubernetes/ceph/common.yaml', - ]) - _kubectl(ctx, config, [ - 'delete', - '-f', 'rook/cluster/examples/kubernetes/ceph/crds.yaml', - ]) + if False: + # don't bother since we'll tear down k8s anyway (and this mysteriously + # fails sometimes when deleting some of the CRDs... not sure why!) + _kubectl(ctx, config, [ + 'delete', + '-f', 'rook/cluster/examples/kubernetes/ceph/common.yaml', + ]) + _kubectl(ctx, config, [ + 'delete', + '-f', 'rook/cluster/examples/kubernetes/ceph/crds.yaml', + ]) ctx.rook[cluster_name].remote.run(args=['rm', '-rf', 'rook', 'operator.yaml']) if op_job: op_job.wait() -- 2.39.5