X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=blobdiff_plain;ds=sidebyside;f=jjb%2Fintegration%2Fcopy-common-functions.sh;h=1ff42d0910536b544f3bb6e2f763f46e659c96f0;hb=ee0114f7f451d4a058ddec6d6d25f60499dca04b;hp=e0eacdf0c1bb5dfba298f0790a1684e3f963a2ba;hpb=13cc1135e78afd64a3ade0c7d12939837f0a177d;p=releng%2Fbuilder.git diff --git a/jjb/integration/copy-common-functions.sh b/jjb/integration/copy-common-functions.sh index e0eacdf0c..1ff42d091 100644 --- a/jjb/integration/copy-common-functions.sh +++ b/jjb/integration/copy-common-functions.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/bin/bash -l # Copy the whole script to /tmp/common-functions.sh and to remote nodes but # only if this script itself is executing and not sourced. jenkins prepends this @@ -11,11 +11,10 @@ if [ "${BASH_SOURCE[0]}" == "${0}" ]; then echo "Copying common-functions.sh to /tmp" cp "${0}" /tmp/common-functions.sh - source /tmp/v/openstack/bin/activate mapfile -t ips <<< "$(openstack stack show -f json -c outputs "$STACK_NAME" | jq -r '.outputs[] | select(.output_key | match("^vm_[0-9]+_ips$")) | .output_value | .[]')" for ip in "${ips[@]}"; do echo "Copying common-functions.sh to ${ip}:/tmp" - scp /tmp/common-functions.sh ${ip}:/tmp + scp /tmp/common-functions.sh "${ip}:/tmp" done exit 0 fi