提交 bc405b15 编写于 作者: N Nadeem Ghani 提交者: Kristofer Macoskey

pipeline: extract pre-run test setup to it's own separate task.

Ideally, pretest setup should be explicit for their own jobs, so we
extracted out the setup to be more modularized.

Any tests should be able to use this pattern instead of having to add it
in run_tinc.yml or run_behave.yml
Signed-off-by: NMarbin Tan <mtan@pivotal.io>
上级 09416670
......@@ -2600,6 +2600,25 @@ jobs:
<<: *ccp_gen_cluster_default_params
on_failure:
<<: *ccp_destroy
- task: pre_run_test_setup
tags: ["ccp"]
image: centos-gpdb-dev-6
config:
platform: linux
inputs:
- name: ccp_src
- name: cluster_env_files
run:
path: bash
args:
- -c
- |
set -ex
ccp_src/aws/setup_ssh_to_cluster.sh
ssh -t mdw "HOST1=mdw HOST2=sdw1 HOST3=sdw2 HOST4=sdw3 HOST5=sdw4 \
bash -c 'ssh-keygen -f ~/.ssh/id_rsa -y > ~/.ssh/id_rsa.pub; for i in mdw sdw{1..4}; do ssh centos@\$i \"sudo chmod 777 /usr/local\"; done'"
on_failure:
<<: *debug_sleep
- task: run_tests
tags: ["ccp"]
file: gpdb_src/concourse/tasks/run_tinc.yml
......@@ -2607,7 +2626,6 @@ jobs:
params:
TINC_TARGET: gpexpand_1
CUSTOM_ENV: HOST1=mdw HOST2=sdw1 HOST3=sdw2 HOST4=sdw3 HOST5=sdw4
PRE_TEST_SCRIPT: bash -c 'ssh-keygen -f ~/.ssh/id_rsa -y > ~/.ssh/id_rsa.pub; for i in mdw sdw{1..4}; do ssh centos@$i "sudo chmod 777 /usr/local"; done'
on_failure:
<<: *debug_sleep
- *ccp_destroy
......@@ -2643,14 +2661,32 @@ jobs:
<<: *ccp_gen_cluster_default_params
on_failure:
<<: *ccp_destroy
- task: pre_run_test_setup
tags: ["ccp"]
image: centos-gpdb-dev-6
config:
platform: linux
inputs:
- name: ccp_src
- name: cluster_env_files
run:
path: bash
args:
- -c
- |
set -ex
ccp_src/aws/setup_ssh_to_cluster.sh
ssh -t mdw "HOST1=mdw HOST2=sdw1 HOST3=sdw2 HOST4=sdw3 HOST5=sdw4 \
bash -c 'ssh-keygen -f ~/.ssh/id_rsa -y > ~/.ssh/id_rsa.pub; for i in mdw sdw{1..4}; do ssh centos@\$i \"sudo chmod 777 /usr/local\"; done'"
on_failure:
<<: *debug_sleep
- task: run_tests
tags: ["ccp"]
file: gpdb_src/concourse/tasks/run_tinc.yml
image: centos-gpdb-dev-6
params:
TINC_TARGET: gpexpand_2
CUSTOM_ENV: HOST1=mdw HOST2=sdw1 HOST3=sdw2 HOST4=sdw3 HOST5=sdw4
PRE_TEST_SCRIPT: bash -c 'ssh-keygen -f ~/.ssh/id_rsa -y > ~/.ssh/id_rsa.pub; for i in mdw sdw{1..4}; do ssh centos@$i "sudo chmod 777 /usr/local"; done'
TINC_TARGET: gpexpand_2
on_failure:
<<: *debug_sleep
- *ccp_destroy
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册