From: DANIEL STOICA Date: Fri, 8 May 2020 13:10:00 +0000 (+0300) Subject: validation:Fix jobs cleanup issue with permissions X-Git-Url: https://gerrit.akraino.org/r/gitweb?a=commitdiff_plain;h=859d3549b7f56cc66289e951cec29ca31ad1b953;p=ci-management.git validation:Fix jobs cleanup issue with permissions Transfer only the ~/.kube/config file for k8s tests, since the rest of contents of the "~/.kube/" directory (e.g. http-cache) might be owned by root, causing permission issues when Jenkins tries to perform the workspace cleanup. Since only the config file is actually needed for running the k8s tests, skip other files/directories in "~/.kube/" Signed-off-by: DANIEL STOICA Change-Id: Ic3d6823bd45069e66eb085a8c09383461f517d12 --- diff --git a/jjb/shell/run_bluval.sh b/jjb/shell/run_bluval.sh index 4284610..4b306a8 100755 --- a/jjb/shell/run_bluval.sh +++ b/jjb/shell/run_bluval.sh @@ -125,10 +125,10 @@ then if [[ -n ${ssh_password} ]] then sshpass -p "${ssh_password}" scp -oUserKnownHostsFile=/dev/null -oStrictHostKeyChecking=no -r\ - "${ssh_user}@${cluster_master_ip}:~/.kube/*" "$k8s_config_dir" + "${ssh_user}@${cluster_master_ip}:~/.kube/config" "$k8s_config_dir" else scp -oUserKnownHostsFile=/dev/null -oStrictHostKeyChecking=no -i"$ssh_key" -r\ - "${ssh_user}"@"${cluster_master_ip}":~/.kube/* "$k8s_config_dir" + "${ssh_user}"@"${cluster_master_ip}":~/.kube/config "$k8s_config_dir" fi fi