aboutsummaryrefslogtreecommitdiffhomepage
path: root/tools/run_tests
diff options
context:
space:
mode:
authorGravatar Stanley Cheung <stanleycheung@google.com>2016-02-10 10:36:20 -0800
committerGravatar Stanley Cheung <stanleycheung@google.com>2016-02-10 10:36:20 -0800
commitd82efd877c93987ccd8f2cb2239e941e37c755f9 (patch)
treef661b3ce0e266fb98ee20fc7db20cb4e97b05ef4 /tools/run_tests
parent31cb8668217f62774a1d80efc3ec59bf9f95db49 (diff)
use HOME env var
Diffstat (limited to 'tools/run_tests')
-rwxr-xr-xtools/run_tests/run_interop_tests.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/tools/run_tests/run_interop_tests.py b/tools/run_tests/run_interop_tests.py
index b8a6637e0c..76be932aef 100755
--- a/tools/run_tests/run_interop_tests.py
+++ b/tools/run_tests/run_interop_tests.py
@@ -535,10 +535,10 @@ def build_interop_image_jobspec(language, tag=None):
env['TTY_FLAG'] = '-t'
# This env variable is used to get around the github rate limit
# error when running the PHP `composer install` command
- # TODO(stanleycheung): find a more elegant way to do this
- if language.safename == 'php' and os.path.exists('/home/jenkins/.composer/auth.json'):
+ host_file = '%s/.composer/auth.json' % os.environ['HOME']
+ if language.safename == 'php' and os.path.exists(host_file):
env['BUILD_INTEROP_DOCKER_EXTRA_ARGS'] = \
- '-v /home/jenkins/.composer/auth.json:/root/.composer/auth.json:ro'
+ '-v %s:/root/.composer/auth.json:ro' % host_file
build_job = jobset.JobSpec(
cmdline=['tools/jenkins/build_interop_image.sh'],
environ=env,