From 95e632475f056a4ca1fef8c71225f9d884a08ab7 Mon Sep 17 00:00:00 2001 From: Josh Durgin Date: Tue, 6 Dec 2011 16:16:38 -0800 Subject: [PATCH] workunit: set client id and secretfile env vars These are used by the kernel rbd workunit to know how to map images. Signed-off-by: Josh Durgin --- teuthology/task/workunit.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/teuthology/task/workunit.py b/teuthology/task/workunit.py index 47aa5107577ef..b024042ab54a3 100644 --- a/teuthology/task/workunit.py +++ b/teuthology/task/workunit.py @@ -101,6 +101,8 @@ def _run_tests(ctx, role, tests): # subdir so we can remove and recreate this a lot without sudo scratch_tmp = os.path.join(mnt, 'client.{id}'.format(id=id_), 'tmp') srcdir = '/tmp/cephtest/workunit.{role}'.format(role=role) + secretfile = '/tmp/cephtest/data/{role}.secret'.format(role=role) + teuthology.write_secret_file(remote, role, secretfile) remote.run( logger=log.getChild(role), @@ -156,6 +158,8 @@ def _run_tests(ctx, role, tests): run.Raw('PATH="$PATH:/tmp/cephtest/binary/usr/local/bin"'), run.Raw('LD_LIBRARY_PATH="$LD_LIBRARY_PATH:/tmp/cephtest/binary/usr/local/lib"'), run.Raw('CEPH_CONF="/tmp/cephtest/ceph.conf"'), + run.Raw('CEPH_SECRET_FILE="{file}"'.format(file=secretfile)), + run.Raw('CEPH_ID="{id}"'.format(id=id_)), run.Raw('PYTHONPATH="$PYTHONPATH:/tmp/cephtest/binary/usr/local/lib/python2.6/dist-packages"'), '/tmp/cephtest/enable-coredump', '/tmp/cephtest/binary/usr/local/bin/ceph-coverage', -- 2.39.5