From e70a83330eaa287fb364aad63829a38b993ad9e7 Mon Sep 17 00:00:00 2001 From: Cristina Pauna Date: Fri, 29 Sep 2017 15:47:59 +0300 Subject: 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 --- tests/ci/load_images.sh | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'tests') 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 -- cgit 1.2.3-korg