]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
workunit: allow parallel git clone
authorLoic Dachary <ldachary@redhat.com>
Thu, 25 Aug 2016 09:34:46 +0000 (11:34 +0200)
committerNathan Cutler <ncutler@suse.com>
Thu, 25 Aug 2016 15:16:26 +0000 (17:16 +0200)
When multiple client run in parallel on the same machine and they
try to get workunits from a repository that is not github, they must
git clone in a directory that is suffixed as srcdir. Otherwise they
will conflict with each other.

Fixes: http://tracker.ceph.com/issues/17116
Signed-off-by: Loic Dachary <loic@dachary.org>
(cherry picked from commit b9813e490ec8a5bb59e177612f047899397c342e)

tasks/workunit.py

index 86bcdb5b9f6456e73c59d1f338328cdbb784e95b..12e5b98db1e7b58ccec6eaa96fbfa0bf7af44f2f 100644 (file)
@@ -288,7 +288,7 @@ def _run_tests(ctx, refspec, role, tests, env, subdir=None, timeout=None):
     else:
         scratch_tmp = os.path.join(mnt, subdir)
     srcdir = '{tdir}/workunit.{role}'.format(tdir=testdir, role=role)
-    clonedir = '{tdir}/clone'.format(tdir=testdir)
+    clonedir = '{tdir}/clone.{role}'.format(tdir=testdir, role=role)
 
     git_url = teuth_config.get_ceph_git_url()
     if 'github.com/ceph/ceph' in git_url: