]> git.apps.os.sepia.ceph.com Git - ceph-build.git/commitdiff
scripts: use find's -delete option to prevent 'argument too long' 1383/head
authorAlfredo Deza <adeza@redhat.com>
Thu, 29 Aug 2019 20:15:53 +0000 (16:15 -0400)
committerAlfredo Deza <adeza@redhat.com>
Thu, 29 Aug 2019 20:15:53 +0000 (16:15 -0400)
Signed-off-by: Alfredo Deza <adeza@redhat.com>
scripts/build_utils.sh

index 689cd437c42e7aa99c094e76fa2432dd3d7a1918..e9e3a4da6339c133467bd2056154b9ec0e365c2e 100644 (file)
@@ -728,7 +728,7 @@ prune_stale_vagrant_vms() {
     shopt -s globstar
 
     # From the global workspace path, find any machine stale from other jobs
-    sudo find $SEARCH_PATH -type d -wholename '*/.vagrant/machines' -exec rm -rv {} +
+    sudo find "$SEARCH_PATH" -type d -path "*/.vagrant/machines/*" -delete
 
     # unset extended pattern globbing, to prevent messing up other functions
     shopt -u globstar