From 81752c48ce4674e9084de3303bfb6f088365b30b Mon Sep 17 00:00:00 2001 From: "carey.xu" Date: Sat, 30 Jan 2016 18:43:30 +0800 Subject: bugfix: rename nic based on mac Change-Id: I2771a87a41ab884dbda1fcffa8ab0833489fb5ef Signed-off-by: carey.xu --- deploy/deploy_host.sh | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'deploy/deploy_host.sh') diff --git a/deploy/deploy_host.sh b/deploy/deploy_host.sh index 1b03f043..9617b241 100755 --- a/deploy/deploy_host.sh +++ b/deploy/deploy_host.sh @@ -8,14 +8,18 @@ # http://www.apache.org/licenses/LICENSE-2.0 ############################################################################## rsa_file=$compass_vm_dir/boot.rsa + +function rename_nics(){ + python $COMPASS_DIR/deploy/rename_nics.py $DHA $rsa_file $MGMT_IP +} + function deploy_host(){ ssh $ssh_args root@${MGMT_IP} mkdir -p /opt/compass/bin/ansible_callbacks scp $ssh_args -r ${COMPASS_DIR}/deploy/status_callback.py root@${MGMT_IP}:/opt/compass/bin/ansible_callbacks/status_callback.py # avoid nodes reboot to fast, cobbler can not give response - (sleep 20;reboot_hosts) & - + (sleep 20; rename_nics; reboot_hosts) & if [[ "$REDEPLOY_HOST" == true ]]; then deploy_flag="redeploy" else -- cgit 1.2.3-korg