]> git-server-git.apps.pok.os.sepia.ceph.com Git - teuthology.git/commitdiff
nuke: Don't attempt to nuke downed nodes 1722/head
authorZack Cerza <zack@redhat.com>
Tue, 8 Feb 2022 19:45:47 +0000 (12:45 -0700)
committerZack Cerza <zack@redhat.com>
Thu, 17 Mar 2022 23:07:38 +0000 (17:07 -0600)
Signed-off-by: Zack Cerza <zack@redhat.com>
teuthology/nuke/__init__.py

index 08d8a52bfa255dc02320c9b7cd73e845a030b8c9..e97bb1deb8125ae994767b5bbe46158df7dad896 100644 (file)
@@ -252,6 +252,11 @@ def nuke(ctx, should_unlock, sync_clocks=True, noipmi=False, keep_logs=False, sh
                         log.info(
                             "Not nuking %s because description doesn't match",
                             lock['name'])
+                    elif lock.get('up') is False:
+                        del ctx.config['targets'][lock['name']]
+                        log.info(
+                            "Not nuking %s because it is down",
+                            lock['name'])
     with parallel() as p:
         for target, hostkey in ctx.config['targets'].items():
             p.spawn(