aboutsummaryrefslogtreecommitdiffstats
path: root/tests/ci/load_images.sh
diff options
context:
space:
mode:
authorCristina Pauna <cristina.pauna@enea.com>2017-09-29 15:47:59 +0300
committerRoss Brattain <ross.b.brattain@intel.com>2017-09-30 01:23:07 -0700
commitc3c086c179c35e0b27bdfe75ac3366f4fa5d6ceb (patch)
tree3401e44f020228675884f89391a09f0248b04243 /tests/ci/load_images.sh
parentce0022a6749b97294166ea0ab7d04a7b06e2cc63 (diff)
Adapt getting the image architecture to mcp
The part which gets the image architecture still uses the old fuel command. Adapted the script to use the mcp command. JIRA: ARMBAND-285 Change-Id: Iddce77c3a856ea11f9994861151db89a402e735e Signed-off-by: Cristina Pauna <cristina.pauna@enea.com>
Diffstat (limited to 'tests/ci/load_images.sh')
-rwxr-xr-xtests/ci/load_images.sh11
1 files changed, 7 insertions, 4 deletions
diff --git a/tests/ci/load_images.sh b/tests/ci/load_images.sh
index c2ae4fe7b..89ebb2dde 100755
--- a/tests/ci/load_images.sh
+++ b/tests/ci/load_images.sh
@@ -13,17 +13,20 @@
set -e
YARD_IMG_ARCH=amd64
-export YARD_IMG_ARCH
if ! grep -q "Defaults env_keep += \"YARD_IMG_ARCH\"" "/etc/sudoers"; then
echo "Defaults env_keep += \"YARD_IMG_ARCH YARDSTICK_REPO_DIR\"" | sudo tee -a /etc/sudoers
fi
# Look for a compute node, that is online, and check if it is aarch64
-ARCH_SCRIPT="ssh \$(fuel2 node list | awk -F'|' '\$6 ~ /compute/ && \$11 ~ /rue/ {print \$7; exit;}') uname -m 2>/dev/null | grep -q aarch64"
-if [ "$INSTALLER_TYPE" == "fuel" ]; then
- sshpass -p r00tme ssh -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no -l root "${INSTALLER_IP}" "${ARCH_SCRIPT}" && YARD_IMG_ARCH=arm64
+if [ "${INSTALLER_TYPE}" == 'fuel' ]; then
+ COMPUTE_ARCH=$(ssh -l ubuntu ${INSTALLER_IP} -i ${SSH_KEY} ${ssh_options} \
+ "sudo salt 'cmp*' grains.get cpuarch --out yaml | awk '{print \$2; exit}'")
+ if [ "${COMPUTE_ARCH}" == 'aarch64' ]; then
+ YARD_IMG_ARCH=arm64
+ fi
fi
+export YARD_IMG_ARCH
HW_FW_TYPE=""
if [ "${YARD_IMG_ARCH}" == "arm64" ]; then