make git clone optional

pull/5102/head
Jan Tattermusch 9 years ago
parent 6c857eab57
commit 92711bbc12
  1. 14
      tools/jenkins/docker_run.sh
  2. 3
      tools/run_tests/distribtest_targets.py

@ -33,16 +33,22 @@
set -e set -e
mkdir -p /var/local/git if [ "$RELATIVE_COPY_PATH" == "" ]
git clone --recursive "$EXTERNAL_GIT_ROOT" /var/local/git/grpc then
mkdir -p /var/local/git
git clone --recursive "$EXTERNAL_GIT_ROOT" /var/local/git/grpc
else
mkdir -p "/var/local/git/grpc/$RELATIVE_COPY_PATH"
cp -r "$EXTERNAL_GIT_ROOT/$RELATIVE_COPY_PATH/*" "/var/local/git/grpc/$RELATIVE_COPY_PATH"
fi
if [ -x "$(command -v rvm)" ] if [ -x "$(command -v rvm)" ]
then then
rvm use ruby-2.1 rvm use ruby-2.1
fi fi
cd /var/local/git/grpc
nvm use 4 || true nvm use 4 || true
cd /var/local/git/grpc
$RUN_COMMAND $RUN_COMMAND

@ -43,7 +43,8 @@ def create_docker_jobspec(name, dockerfile_dir, shell_command, environ={},
for k,v in environ.iteritems(): for k,v in environ.iteritems():
docker_args += ['-e', '%s=%s' % (k, v)] docker_args += ['-e', '%s=%s' % (k, v)]
docker_env = {'DOCKERFILE_DIR': dockerfile_dir, docker_env = {'DOCKERFILE_DIR': dockerfile_dir,
'DOCKER_RUN_SCRIPT': 'tools/jenkins/docker_run.sh'} 'DOCKER_RUN_SCRIPT': 'tools/jenkins/docker_run.sh',
'RELATIVE_COPY_PATH': 'test/distrib'}
jobspec = jobset.JobSpec( jobspec = jobset.JobSpec(
cmdline=['tools/jenkins/build_and_run_docker.sh'] + docker_args, cmdline=['tools/jenkins/build_and_run_docker.sh'] + docker_args,
environ=docker_env, environ=docker_env,

Loading…
Cancel
Save