Merge "add trustme exec for bare node"

This commit is contained in:
Jenkins 2016-08-27 02:20:57 +00:00 committed by Gerrit Code Review
commit 59f51fc1d8
2 changed files with 3 additions and 1 deletions

View File

@ -53,7 +53,7 @@ if [ $? != 0 ]; then
print_log "delete pub key of $ip from known_hosts failed"
exit 1
fi
sshpass -p $passwd ssh -o StrictHostKeyChecking=no $ip "touch ~/.ssh/authorized_keys"
sshpass -p $passwd ssh -o StrictHostKeyChecking=no $ip "mkdir -p ~/.ssh && touch ~/.ssh/authorized_keys"
if [ $? != 0 ]; then
print_log "ssh $ip to create file authorized_keys failed"
exit 1

View File

@ -340,6 +340,8 @@ class KOLLAInstallTask(Thread):
with open(self.log_file, "w+") as fp:
for host in hosts_list:
host_ip = host['mgtip']
cmd = '/var/lib/daisy/kolla/trustme.sh %s ossdbg1' % host_ip
daisy_cmn.subprocess_call(cmd, fp)
config_nodes_hosts(host_name_ip_list, host_ip)
cmd = 'sshpass -p ossdbg1 ssh -o StrictHostKeyChecking=no %s \
"if [ ! -d %s ];then mkdir %s;fi" ' % \