-
aticig authored
Signed-off-by:
Gulsum Atici <gulsum.atici@canonical.com>
566c497b
Code owners
Assign users and groups as approvers for specific file changes. Learn more.
run-vm-initial-setup.sh 699 B
#!/bin/bash
echo $0 started at $(date)
. ./common-vars $@
. ./main_credentials.rc
for PARTICIPANT in `seq ${START} ${MAX}` ; do
VM_NAME=`expr charmedosm-${PARTICIPANT}`
IP=`openstack server list --name $VM_NAME --column Networks -f yaml | head -3 | tail -1 | grep -o '[0-9]\+[.][0-9]\+[.][0-9]\+[.][0-9]\+'`
echo $IP
scp -o StrictHostKeyChecking=no -i hackfest_rsa ./vm-initial-setup.sh ubuntu@${IP}: &
scp -o StrictHostKeyChecking=no -i hackfest_rsa ./hackfest15admin.pub ubuntu@${IP}: &
sleep 10
ssh -o StrictHostKeyChecking=no -i hackfest_rsa ubuntu@${IP} ". ~/vm-initial-setup.sh" 2>&1 | tee -a logs/vm-initial-setup-${PARTICIPANT}.log &
done
wait
echo $0 $@ complete at $(date)